Compartir a través de


ChildItemCmdletProviderIntrinsics.HasChild Method

Definition

Overloads

HasChild(String)

Determines if an item at the given path has children.

HasChild(String, Boolean, Boolean)

Determines if an item at the given path has children.

HasChild(String)

Determines if an item at the given path has children.

public:
 bool HasChild(System::String ^ path);
public:
 bool HasChild(Platform::String ^ path);
bool HasChild(std::wstring const & path);
public bool HasChild (string path);
member this.HasChild : string -> bool
Public Function HasChild (path As String) As Boolean

Parameters

path
String

The path to the item to determine if it has children. It may be a drive or provider-qualified path and may include glob characters.

Returns

True if the item at the specified path has children. False otherwise.

Exceptions

If path is null.

If the path refers to a provider that could not be found.

If the path refers to a drive that could not be found.

If path does not contain glob characters and could not be found.

If the provider that the path refers to does not support this operation.

If the provider threw an exception.

Applies to

HasChild(String, Boolean, Boolean)

Determines if an item at the given path has children.

public:
 bool HasChild(System::String ^ path, bool force, bool literalPath);
public:
 bool HasChild(Platform::String ^ path, bool force, bool literalPath);
bool HasChild(std::wstring const & path, bool force, bool literalPath);
public bool HasChild (string path, bool force, bool literalPath);
member this.HasChild : string * bool * bool -> bool
Public Function HasChild (path As String, force As Boolean, literalPath As Boolean) As Boolean

Parameters

path
String

The path to the item to determine if it has children. It may be a drive or provider-qualified path and may include glob characters.

force
Boolean

Passed on to providers to force operations.

literalPath
Boolean

If true, globbing is not done on paths.

Returns

True if the item at the specified path has children. False otherwise.

Exceptions

If path is null.

If the path refers to a provider that could not be found.

If the path refers to a drive that could not be found.

If path does not contain glob characters and could not be found.

If the provider that the path refers to does not support this operation.

If the provider threw an exception.

Applies to