SamlSerializer.WriteToken Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Writes the specified SAML security token into the specified XML serializer.
public:
virtual void WriteToken(System::IdentityModel::Tokens::SamlSecurityToken ^ token, System::Xml::XmlWriter ^ writer, System::IdentityModel::Selectors::SecurityTokenSerializer ^ keyInfoSerializer);
public virtual void WriteToken (System.IdentityModel.Tokens.SamlSecurityToken token, System.Xml.XmlWriter writer, System.IdentityModel.Selectors.SecurityTokenSerializer keyInfoSerializer);
abstract member WriteToken : System.IdentityModel.Tokens.SamlSecurityToken * System.Xml.XmlWriter * System.IdentityModel.Selectors.SecurityTokenSerializer -> unit
override this.WriteToken : System.IdentityModel.Tokens.SamlSecurityToken * System.Xml.XmlWriter * System.IdentityModel.Selectors.SecurityTokenSerializer -> unit
Public Overridable Sub WriteToken (token As SamlSecurityToken, writer As XmlWriter, keyInfoSerializer As SecurityTokenSerializer)
Parameters
- token
- SamlSecurityToken
The SamlSecurityToken to write.
- writer
- XmlWriter
An XmlDictionaryWriter to write the SAML authorization statement.
- keyInfoSerializer
- SecurityTokenSerializer
A SecurityTokenSerializer that is capable of writing KeyInfo
clauses.
Exceptions
Remarks
Use the WriteToken(SamlSecurityToken, XmlWriter, SecurityTokenSerializer) method to serialize a SamlSecurityToken security token. To deserialize a SamlSecurityToken use the ReadToken(XmlReader, SecurityTokenSerializer, SecurityTokenResolver) method.