PathUtil.IsDescendant(String, String) 方法

定义

指示子路径是否为父目录的后代。 这是纯文本计算,指示子对象 可以是 父级的后代;没有任何文件系统交互来确定子级是否确实 父级的后代。

public:
 static bool IsDescendant(System::String ^ parent, System::String ^ child);
public:
 static bool IsDescendant(Platform::String ^ parent, Platform::String ^ child);
 static bool IsDescendant(std::wstring const & parent, std::wstring const & child);
public static bool IsDescendant (string parent, string child);
static member IsDescendant : string * string -> bool
Public Function IsDescendant (parent As String, child As String) As Boolean

参数

parent
String

父目录

child
String

预期的子文件/目录

返回

Boolean

如果为 True,则为 True; 否则为 false

适用于