Public NotInheritable Class PSCredential
public sealed class PSCredential
public ref class PSCredential sealed
public final class PSCredential
To create a secure cmdlet or Windows PowerShell provider, define a single parameter of this type instead of using separate parameters for the user name and password.
Do not use the constructor that is provided by this class directly to specify credentials. From scripts, use the Get-credential cmdlet; from code, call the PromptForCredential method.