System.Security.ISecurityPolicyEncodable Interface

Assembly: Mscorlib.dll
Namespace: System.Security
Summary
Supports the methods that convert permission object state to and from an XML element representation.
C# Syntax:
public interface ISecurityPolicyEncodable
Remarks
This interface is similar to ISecurityEncodable, with the exception that it includes policy-level context. Policy level is needed to resolve references to named permission sets.
See also:
System.Security Namespace

System.Security.ISecurityPolicyEncodable Member List:

Public Methods
FromXml Reconstructs a security object with a specified state from an XML encoding.
ToXml Creates an XML encoding of the security object and its current state.

System.Security.ISecurityPolicyEncodable Member Details

Method: FromXml(
   SecurityElement e,
   PolicyLevel level
)
Summary
Reconstructs a security object with a specified state from an XML encoding.
C# Syntax:
void FromXml(
   SecurityElement e,
   PolicyLevel level
);
Parameters:

e

The XML encoding to use to reconstruct the security object.

level

The policy-level context to resolve named permission set references.

Remarks
Custom code that extends security policy objects needs to implement the ISecurityPolicyEncodable.ToXml and ISecurityPolicyEncodable.FromXml methods to make the objects security-encodable.

Return to top


Method: ToXml(
   PolicyLevel level
)
Summary
Creates an XML encoding of the security object and its current state.
C# Syntax:
SecurityElement ToXml(
   PolicyLevel level
);
Parameters:

level

The policy-level context to resolve named permission set references.

Return Value:
The root element of the XML representation of the policy object.
Remarks
The policy-level context is provided for resolution of named permission set references. For example, code groups use policy level to find named permission sets by name.

Custom code that extends security policy objects needs to implement the ISecurityPolicyEncodable.ToXml and ISecurityPolicyEncodable.FromXml methods to make the objects security-encodable.

Return to top


Top of page

Copyright (c) 2002 Microsoft Corporation. All rights reserved.