ECDiffieHellmanCng.ToXmlString 方法

定义

将密钥信息序列化为 XML 字符串。Serializes the key information to an XML string.

重载

ToXmlString(ECKeyXmlFormat)

使用指定的格式将密钥信息序列化为 XML 字符串。Serializes the key information to an XML string by using the specified format.

ToXmlString(Boolean)

未实现此方法。This method is not implemented.

ToXmlString(ECKeyXmlFormat)

使用指定的格式将密钥信息序列化为 XML 字符串。Serializes the key information to an XML string by using the specified format.

public:
 System::String ^ ToXmlString(System::Security::Cryptography::ECKeyXmlFormat format);
public string ToXmlString (System.Security.Cryptography.ECKeyXmlFormat format);
override this.ToXmlString : System.Security.Cryptography.ECKeyXmlFormat -> string
Public Function ToXmlString (format As ECKeyXmlFormat) As String

参数

format
ECKeyXmlFormat

枚举值之一,它指定 XML 字符串的格式。One of the enumeration values that specifies the format of the XML string. 当前接受的唯一格式为 Rfc4050The only currently accepted format is Rfc4050.

返回

String

一个包含密钥信息的字符串对象,该密钥信息已根据请求的格式序列化为 XML 字符串。A string object that contains the key information, serialized to an XML string, according to the requested format.

例外

format 指定的格式无效。format specifies an invalid format. 唯一接受的值为 Rfc4050The only accepted value is Rfc4050.

适用于

ToXmlString(Boolean)

未实现此方法。This method is not implemented.

public:
 override System::String ^ ToXmlString(bool includePrivateParameters);
public override string ToXmlString (bool includePrivateParameters);
override this.ToXmlString : bool -> string
Public Overrides Function ToXmlString (includePrivateParameters As Boolean) As String

参数

includePrivateParameters
Boolean

若要包含专用参数,则为 true;否则为 falsetrue to include private parameters; otherwise, false.

返回

String

不适用。Not applicable.

例外

未重写此实例的方法。This method was not overridden for this instance.

注解

若要将当前键转换为 XML 表示形式,请改用 ToXmlString(ECKeyXmlFormat) 重载。To convert the current key to an XML representation, use the ToXmlString(ECKeyXmlFormat) overload instead.

适用于