共用方式為


DeserializePolicy 方法

Deserializes a single policy and its associated condition from the specified XML reader into the policy store.

命名空間:  Microsoft.SqlServer.Management.Dmf
組件:  Microsoft.SqlServer.Dmf (在 Microsoft.SqlServer.Dmf.dll 中)

語法

'宣告
Public Function DeserializePolicy ( _
    xmlReader As XmlReader, _
    overwriteExistingPolicy As Boolean, _
    overwriteExistingCondition As Boolean _
) As Policy
'用途
Dim instance As PolicyStore
Dim xmlReader As XmlReader
Dim overwriteExistingPolicy As Boolean
Dim overwriteExistingCondition As Boolean
Dim returnValue As Policy

returnValue = instance.DeserializePolicy(xmlReader, _
    overwriteExistingPolicy, overwriteExistingCondition)
public Policy DeserializePolicy(
    XmlReader xmlReader,
    bool overwriteExistingPolicy,
    bool overwriteExistingCondition
)
public:
Policy^ DeserializePolicy(
    XmlReader^ xmlReader, 
    bool overwriteExistingPolicy, 
    bool overwriteExistingCondition
)
member DeserializePolicy : 
        xmlReader:XmlReader * 
        overwriteExistingPolicy:bool * 
        overwriteExistingCondition:bool -> Policy 
public function DeserializePolicy(
    xmlReader : XmlReader, 
    overwriteExistingPolicy : boolean, 
    overwriteExistingCondition : boolean
) : Policy

參數

  • overwriteExistingPolicy
    型別:System. . :: . .Boolean
    A Boolean value that specifies whether the existing policy is overwritten during the deserialization.
  • overwriteExistingCondition
    型別:System. . :: . .Boolean
    A Boolean value that specifies whether the existing condition is overwritten during the deserialization.

傳回值

型別:Microsoft.SqlServer.Management.Dmf. . :: . .Policy
A Policy and its associated condition from the specified XML reader into the policy store.

備註

The deserialized policy and condition exists in-memory only.