共用方式為


ExpressionNode.ConvertFromFilterNode 方法 (FilterNode)

Creates a new expression node by converting a filter node.

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

語法

'宣告
Public Shared Function ConvertFromFilterNode ( _
    filterNode As FilterNode _
) As ExpressionNode
'用途
Dim filterNode As FilterNode 
Dim returnValue As ExpressionNode 

returnValue = ExpressionNode.ConvertFromFilterNode(filterNode)
public static ExpressionNode ConvertFromFilterNode(
    FilterNode filterNode
)
public:
static ExpressionNode^ ConvertFromFilterNode(
    FilterNode^ filterNode
)
static member ConvertFromFilterNode : 
        filterNode:FilterNode -> ExpressionNode
public static function ConvertFromFilterNode(
    filterNode : FilterNode
) : ExpressionNode

參數

傳回值

型別:Microsoft.SqlServer.Management.Dmf.ExpressionNode
An ExpressionNode object that represents the new expression node.

備註

This allows you to create expression node that refers to an object or a group of objects defined by the filter.

範例

C#

string xpath = "Server/Database[like(@Name, 'msdb') or like(@Name,'m[as]%')]";
Urn urn = new SFC.Urn (xpath);
FilterNode fnode = urn.XPathExpression[urn.XPathExpression.Length - 1].Filter;
ExpressionNode node = ExpressionNode.ConvertFromFilterNode(fnode);

Note Urn and FilterNode are SFC classes.

請參閱

參考

ExpressionNode 類別

ConvertFromFilterNode 多載

Microsoft.SqlServer.Management.Dmf 命名空間