Provider cmdlets

 

The cmdlets that the user can run to manage a data store are referred to as provider cmdlets. To support these cmdlets, you need to overwrite some of the methods defined by the base provider classes and interfaces.

Here are the provider cmdlets that can be run by the user:

  • Get-PSDrive: This cmdlet returns the Windows PowerShell drives in the current session. You do not need to overwrite any methods to support this cmdlet.

  • New-PSDrive: This cmdlet allows the user to create Windows PowerShell drives to access the data store. To support this cmdlet, overwrite the DriveCmdletProvider.NewDrive and DriveCmdletProvider.NewDriveDynamicParameters methods.

  • Remove-PSDrive: This cmdlet allows the user to remove Windows PowerShell drives that access the data store. To support this cmdlet, overwrite the DriveCmdletProvider.RemoveDrive method.

  • Get-Location: Retrieves information about the current working location. You do not need to overwrite any methods to support this cmdlet.

  • Pop-Location: This cmdlet changes the current location to the location most recently pushed onto the stack. You do not need to overwrite any methods to support this cmdlet.

  • Push-Location: This cmdlet adds the current location to the top of a list of locations (a "stack"). You do not need to overwrite any methods to support this cmdlet.

  • Set-Location: This cmdlet sets the current working location to a specified location. You do not need to overwrite any methods to support this cmdlet.

  • Join-Path: This cmdlet allows the user to combine a parent and child path segment to create a provider-internal path. To support this cmdlet, overwrite the NavigationCmdletProvider.MakePath method.

  • Convert-Path: This cmdlet converts a path from a Windows PowerShell path to a Windows PowerShell provider path.

  • Split-Path: Returns the specified part of a path.

  • Resolve-Path: Resolves the wildcard characters in a path, and displays the path contents.

  • Test-Path: This cmdlet determines whether all elements of a path exist. To support this cmdlet, overwrite the ItemCmdletProvider.ItemExists and ItemCmdletProvider.ItemExistsDynamicParameters methods.

  • Get-PSProvider: This cmdlet returns information about the providers available in the session. You do not need to overwrite any methods to support this cmdlet.

Show: