Partilhar via


CmdletBindingAttribute Class

Definition

Identifies PowerShell script code as behaving like a cmdlet and hence uses cmdlet parameter binding instead of script parameter binding.

public ref class CmdletBindingAttribute : System::Management::Automation::CmdletCommonMetadataAttribute
[System.AttributeUsage(System.AttributeTargets.Class)]
public class CmdletBindingAttribute : System.Management.Automation.CmdletCommonMetadataAttribute
[<System.AttributeUsage(System.AttributeTargets.Class)>]
type CmdletBindingAttribute = class
    inherit CmdletCommonMetadataAttribute
Public Class CmdletBindingAttribute
Inherits CmdletCommonMetadataAttribute
Inheritance
Attributes

Constructors

CmdletBindingAttribute()

Properties

ConfirmImpact

Gets or sets a ConfirmImpact value that indicates the "destructiveness" of the operation and when it should be confirmed. This should only be used when SupportsShouldProcess is specified.

(Inherited from CmdletCommonMetadataAttribute)
DefaultParameterSetName

Gets or sets the cmdlet default parameter set.

(Inherited from CmdletCommonMetadataAttribute)
HelpUri

Gets or sets a HelpUri value that indicates the location of online help. This is used by Get-Help to retrieve help content when -Online is specified.

(Inherited from CmdletCommonMetadataAttribute)
PositionalBinding

When true, the script will auto-generate appropriate parameter metadata to support positional parameters if the script hasn't already specified multiple parameter sets or specified positions explicitly via the ParameterAttribute.

RemotingCapability

Gets or sets the RemotingBehavior value that declares how this cmdlet should interact with ambient remoting.

(Inherited from CmdletCommonMetadataAttribute)
SupportsPaging

Gets or sets a Boolean value that indicates the Cmdlet supports Paging. By default the value is false, meaning the cmdlet doesn't support Paging.

(Inherited from CmdletCommonMetadataAttribute)
SupportsShouldProcess

Gets or sets a Boolean value that indicates the Cmdlet supports ShouldProcess. By default the value is false, meaning the cmdlet doesn't support ShouldProcess.

(Inherited from CmdletCommonMetadataAttribute)
SupportsTransactions

Gets or sets a Boolean value that indicates the Cmdlet supports Transactions. By default the value is false, meaning the cmdlet doesn't support Transactions.

(Inherited from CmdletCommonMetadataAttribute)

Applies to