Condividi tramite


CodeTypeDeclarationCollection.Remove(CodeTypeDeclaration) Metodo

Definizione

Rimuove l'oggetto CodeTypeDeclaration specificato dalla raccolta.

public:
 void Remove(System::CodeDom::CodeTypeDeclaration ^ value);
public void Remove (System.CodeDom.CodeTypeDeclaration value);
member this.Remove : System.CodeDom.CodeTypeDeclaration -> unit
Public Sub Remove (value As CodeTypeDeclaration)

Parametri

value
CodeTypeDeclaration

Oggetto CodeTypeDeclaration da rimuovere dalla raccolta.

Eccezioni

Impossibile trovare l'oggetto specificato nell'insieme.

Esempio

Nell'esempio seguente viene illustrato come usare il Remove metodo per eliminare un CodeTypeDeclaration oggetto da un CodeTypeDeclarationCollectionoggetto .

// Removes the specified CodeTypeDeclaration from the collection.
CodeTypeDeclaration^ declaration = gcnew CodeTypeDeclaration( "TestType" );
collection->Remove( declaration );
// Removes the specified CodeTypeDeclaration from the collection.
CodeTypeDeclaration declaration = new CodeTypeDeclaration("TestType");
collection.Remove( declaration );
' Removes the specified CodeTypeDeclaration from the collection.
Dim declaration As New CodeTypeDeclaration("TestType")
collection.Remove(declaration)

Si applica a