VCCodeIDLCoClass Schnittstelle
Definition
Ein Objekt, das ein coclass-Element in einer IDL-Datei definiert.An object defining a CoClass element in a .idl file.
public interface class VCCodeIDLCoClass
public interface class VCCodeIDLCoClass
__interface VCCodeIDLCoClass
[System.Runtime.InteropServices.Guid("D9934CD0-5E33-4744-A939-664BE7E1B6D9")]
[System.Runtime.InteropServices.TypeLibType(System.Runtime.InteropServices.TypeLibTypeFlags.FDispatchable | System.Runtime.InteropServices.TypeLibTypeFlags.FDual)]
public interface VCCodeIDLCoClass
[<System.Runtime.InteropServices.Guid("D9934CD0-5E33-4744-A939-664BE7E1B6D9")>]
[<System.Runtime.InteropServices.TypeLibType(System.Runtime.InteropServices.TypeLibTypeFlags.FDispatchable | System.Runtime.InteropServices.TypeLibTypeFlags.FDual)>]
type VCCodeIDLCoClass = interface
Public Interface VCCodeIDLCoClass
- Attribute
Beispiele
Dieses Beispiel ruft die erste coclass-Code Anweisung ab und zeigt Sie in einem Meldungs Feld an.This example retrieves the first CoClass code statement and displays it in a message box.
Sub GetFirstCoClass()
Dim vcCM As VCCodeModel
Dim vcIDLCoClass As VCCodeIDLCoClass
vcCM = DTE.Solution.Item(1).CodeModel
vcIDLCoClass = vcCM.IDLLibraries.Item(1).IDLCoClasses.Item(1)
MsgBox(vcIDLCoClass.DisplayName)
End Sub
Hinweise
Das- VCCodeIDLCoClass Objekt stellt ein coclass-Code Element aus der IDL-Datei der übergeordneten Projekt Mappe dar.The VCCodeIDLCoClass object represents a CoClass code element from the .idl file of the parent solution. Hauptsächlich wird dieses Objekt verwendet, um auf die Elemente eines vorhandenen coclass-Code Elements zuzugreifen.Primarily, this object is used to access the elements of an existing CoClass code element.
Weitere Informationen zum Kompilieren und Ausführen dieses Beispiels finden Sie unter Gewusst wie: Kompilieren von Beispielcode für die Erweiterbarkeit von Visual C++-Code Modellen .See How to: Compile Example Code for Visual C++ Code Model Extensibility for information on how to compile and run this sample.
Eigenschaften
Attributes |
Ruft eine Auflistung aller Attribute für das Objekt ab.Gets a collection of all of the attributes for the object. |
BodyText |
Ruft den Textkörper des Objekts ab oder legt diesen fest.Gets or sets the body text of the object. |
Children |
Ruft eine Auflistung von Objekten ab, die in diesem Codekonstrukt enthalten sind.Gets a collection of objects contained within this code construct. |
CodeModel |
Ruft das VCCodeModel-Objekt für das Projekt ab.Gets the VCCodeModel object for the project. |
Collection |
Ruft die Auflistung mit dem Objekt ab, das diese Eigenschaft unterstützt oder das in diesem Codekonstrukt enthalten ist.Gets the collection containing the object supporting this property or contained within this code construct. |
Comment |
Ruft den zum Codeelement zugeordneten Kommentar ab oder legt diesen fest.Gets or sets the comment associated with the code element. |
DeclarationText |
Ruft die Deklaration des Objekts ab oder legt diese fest.Gets or sets the declaration of the object. |
DisplayName |
Ruft den vollständigen Namen des Objekts ab.Gets the full name of the object. |
DTE |
Ruft das Erweiterbarkeitsobjekt der obersten Ebene ab.Gets the top-level extensibility object. |
EndPoint |
Ruft den Bearbeitungspunkt ab, der die Position am Ende des Codeelements darstellt.Gets the edit point that is the location of the end of the code item. |
EndPointOf[vsCMPart, vsCMWhere] |
Ruft den Endpunkt des übergeordneten Objekts ab.Gets the end point of the parent object. |
Extender[String] |
Ruft das angeforderte Extenderobjekt ab, falls es für dieses Objekt verfügbar ist.Gets the requested Extender object if it is available for this object. |
ExtenderCATID |
Ruft die ID der Extenderkategorie (CATID) für das Objekt ab.Gets the Extender category ID (CATID) for the object. |
ExtenderNames |
Ruft eine Liste der für das Objekt verfügbaren Extender ab.Gets a list of available Extenders for the object. |
File |
Ruft die Datei ab, in der das Objekt deklariert ist.Gets the file in which the object is declared. |
FullName |
Ruft den vollständigen Pfad und Namen der Objektdatei ab.Gets the full path and name of the object's file. |
InfoLocation |
Ruft die Funktionen des Codemodells ab.Gets the capabilities of the code model. |
IsCaseSensitive |
Ruft einen Wert ab, der angibt, ob bei einem Codeelement die Groß-/Kleinschreibung beachtet wird.Gets a value indicating whether a code element is case-sensitive. |
IsCodeType |
Ruft einen Wert ab, der angibt, ob ein CodeType-Objekt aus diesem Objekt abgerufen werden kann.Gets a value indicating whether a CodeType object can be obtained from this object. |
IsInjected |
Ruft einen Wert ab, der angibt, ob ein Codeelement durch ein Attribut oder eine Makroerweiterung eingefügt wurde.Gets a value indicating whether a code element has been injected by an attribute or macro expansion. |
IsReadOnly |
Ruft einen Wert ab, der angibt, ob die Datei, die das Objekt enthält, schreibgeschützt ist.Gets a value indicating whether the file containing the object is read-only. |
IsZombie |
Ruft einen Wert ab, der angibt, ob das übergeordnete Objekt existiert.Gets a value indicating whether the parent object exists. |
Kind |
Ruft eine Enumeration ab, die den Typ des Objekts angibt.Gets an enumeration indicating the type of object. |
Language |
Ruft die Programmiersprache ab, die die zum Schreiben des Codes verwendet wurde.Gets the programming language used to author the code. |
Location[vsCMWhere] |
Ruft den Speicherort der Objektdeklaration ab.Gets the location of the object declaration. |
Name |
Ruft den Namen des Objekts ab oder legt ihn fest.Gets or sets the name of the object. |
Parent |
Ruft das unmittelbar übergeordnete Objekt eines VCCodeIDLCoClass-Objekts ab.Gets the immediate parent object of a VCCodeIDLCoClass object. |
Picture |
Ruft ein Bildautomatisierungsobjekt ab, das als Symbol in der Benutzerschnittstelle verwendet werden soll.Gets a picture automation object to be used as an icon in the user interface. |
Project |
Ruft das dem Objekt zugeordnete Project ab.Gets the Project associated with the object. |
ProjectItem |
Ruft das dem angegebenen Objekt zugeordnete ProjectItem-Objekt ab.Gets the ProjectItem object associated with the given object. |
StartPoint |
Ruft ein TextPoint-Objekt ab, das den Anfang des Codeelements definiert.Gets a TextPoint object that defines the beginning of the code item. |
StartPointOf[vsCMPart, vsCMWhere] |
Ruft den Startpunkt des Objekts ab.Gets the start point of the object. |
Methoden
AddAttribute(String, String, Object) |
Erstellt ein neues Attribut-Codekonstrukt und fügt den Code am korrekten Ort ein.Creates a new attribute code construct and inserts the code in the correct location. |
GetEndPoint(vsCMPart) |
Ruft ein TextPoint-Objekt ab, das das Ende der Codeelementdefinition markiert.Gets a TextPoint object that marks the end of the code element definition. |
GetStartPoint(vsCMPart) |
Ruft ein TextPoint-Objekt ab, das den Anfang der Codeelementdefinition definiert.Gets a TextPoint object that defines the beginning of the code element definition. |
IsSelf(Object) |
Ermittelt, ob das angegebene Codeelement mit einem anderen Codeelement identisch ist.Determines if the specified code element is the same as another code element. |