CodeAttributeDeclaration 建構函式
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
初始化 CodeAttributeDeclaration 類別的新執行個體。
多載
| 名稱 | Description |
|---|---|
| CodeAttributeDeclaration() |
初始化 CodeAttributeDeclaration 類別的新執行個體。 |
| CodeAttributeDeclaration(CodeTypeReference) |
使用指定的程式碼型別參考初始化該 CodeAttributeDeclaration 類別的新實例。 |
| CodeAttributeDeclaration(String) |
使用指定名稱初始化該類別的新實例 CodeAttributeDeclaration 。 |
| CodeAttributeDeclaration(CodeTypeReference, CodeAttributeArgument[]) |
使用指定的程式碼類型參考與參數初始化該 CodeAttributeDeclaration 類別的新實例。 |
| CodeAttributeDeclaration(String, CodeAttributeArgument[]) |
使用指定的名稱和參數初始化該類別的新實例 CodeAttributeDeclaration 。 |
CodeAttributeDeclaration()
初始化 CodeAttributeDeclaration 類別的新執行個體。
public:
CodeAttributeDeclaration();
public CodeAttributeDeclaration();
Public Sub New ()
適用於
CodeAttributeDeclaration(CodeTypeReference)
使用指定的程式碼型別參考初始化該 CodeAttributeDeclaration 類別的新實例。
public:
CodeAttributeDeclaration(System::CodeDom::CodeTypeReference ^ attributeType);
public CodeAttributeDeclaration(System.CodeDom.CodeTypeReference attributeType);
new System.CodeDom.CodeAttributeDeclaration : System.CodeDom.CodeTypeReference -> System.CodeDom.CodeAttributeDeclaration
Public Sub New (attributeType As CodeTypeReference)
參數
- attributeType
- CodeTypeReference
那 CodeTypeReference 個就是屬性的識別。
備註
參數 attributeType 用來設定 AttributeType 和 Name 屬性。
另請參閱
適用於
CodeAttributeDeclaration(String)
使用指定名稱初始化該類別的新實例 CodeAttributeDeclaration 。
public:
CodeAttributeDeclaration(System::String ^ name);
public CodeAttributeDeclaration(string name);
new System.CodeDom.CodeAttributeDeclaration : string -> System.CodeDom.CodeAttributeDeclaration
Public Sub New (name As String)
參數
- name
- String
屬性的名稱。
適用於
CodeAttributeDeclaration(CodeTypeReference, CodeAttributeArgument[])
使用指定的程式碼類型參考與參數初始化該 CodeAttributeDeclaration 類別的新實例。
public:
CodeAttributeDeclaration(System::CodeDom::CodeTypeReference ^ attributeType, ... cli::array <System::CodeDom::CodeAttributeArgument ^> ^ arguments);
public CodeAttributeDeclaration(System.CodeDom.CodeTypeReference attributeType, params System.CodeDom.CodeAttributeArgument[] arguments);
new System.CodeDom.CodeAttributeDeclaration : System.CodeDom.CodeTypeReference * System.CodeDom.CodeAttributeArgument[] -> System.CodeDom.CodeAttributeDeclaration
Public Sub New (attributeType As CodeTypeReference, ParamArray arguments As CodeAttributeArgument())
參數
- attributeType
- CodeTypeReference
那 CodeTypeReference 個就是屬性的識別。
- arguments
- CodeAttributeArgument[]
一個型別 CodeAttributeArgument 為的陣列,包含屬性的參數。
備註
參數attributeType用於設定 AttributeType 和 Name 屬性,arguments參數則用於設定 屬性CodeAttributeDeclaration。Arguments
另請參閱
適用於
CodeAttributeDeclaration(String, CodeAttributeArgument[])
使用指定的名稱和參數初始化該類別的新實例 CodeAttributeDeclaration 。
public:
CodeAttributeDeclaration(System::String ^ name, ... cli::array <System::CodeDom::CodeAttributeArgument ^> ^ arguments);
public CodeAttributeDeclaration(string name, params System.CodeDom.CodeAttributeArgument[] arguments);
new System.CodeDom.CodeAttributeDeclaration : string * System.CodeDom.CodeAttributeArgument[] -> System.CodeDom.CodeAttributeDeclaration
Public Sub New (name As String, ParamArray arguments As CodeAttributeArgument())
參數
- name
- String
屬性的名稱。
- arguments
- CodeAttributeArgument[]
一個型別 CodeAttributeArgument 為的陣列,包含屬性的參數。