IGeneralization 介面

兩個分類器之間的關聯性,在這兩個關聯器中,特定分類器會繼承與擴大一般分類器的某些功能。取決於功能如何定義的具體的分類器的實例可能也算一般分類器的實例。

命名空間:  Microsoft.VisualStudio.Uml.Classes
組件:  Microsoft.VisualStudio.Uml.Interfaces (在 Microsoft.VisualStudio.Uml.Interfaces.dll 中)

語法

'宣告
Public Interface IGeneralization _
    Inherits IDirectedRelationship, IRelationship, IElement
public interface IGeneralization : IDirectedRelationship, 
    IRelationship, IElement
public interface class IGeneralization : IDirectedRelationship, 
    IRelationship, IElement
type IGeneralization =  
    interface
        interface IDirectedRelationship
        interface IRelationship
        interface IElement
    end
public interface IGeneralization extends IDirectedRelationship, IRelationship, IElement

IGeneralization 型別會公開下列成員。

屬性

  名稱 說明
公用屬性 ApplicableStereotypes 可套用至此項目的一組造型。 (繼承自 IElement)。
公用屬性 AppliedStereotypes 每個 IStereotypeInstance 都表示已將造型套用至此元素。 (繼承自 IElement)。
公用屬性 Description 這個項目的描述。 (繼承自 IElement)。
公用屬性 General 特定分類器特製化的分類器。
公用屬性 IsSubstitutable 如果在任何需要一般分類器執行個體的位置上都可以接受特定分類器的執行個體,則為 true。
公用屬性 OwnedComments 取得此元素中包含的註解 (非連結到它的註解)。 (繼承自 IElement)。
公用屬性 OwnedElements 取得此元素所擁有的元素。每個元素都有一個擁有者,除了根 IModel 以外。 (繼承自 IElement)。
公用屬性 Owner 取得擁有這個項目的項目。除了根 IModel 以外的每個元素都有一個擁有者。 (繼承自 IElement)。
公用屬性 Source 關聯性的來源項目。 (繼承自 IDirectedRelationship)。
公用屬性 SourceElement 關聯性的來源要素。 (繼承自 IRelationship)。
公用屬性 Specific 透過新增資訊至一般化分類器所定義的分類器。
公用屬性 Target 關聯性的目標項目。 (繼承自 IDirectedRelationship)。
公用屬性 TargetElement 關聯性的目標元素。 (繼承自 IRelationship)。
公用屬性 VisibleAppliedStereotypes (繼承自 IElement)。

回頁首

擴充方法

  名稱 說明
公用擴充方法 AddReference 將字串連結到元素,通常該字串是像 URI、modelbus 參考或工作項目 ID 之類的參考。使用名稱來顯示參考的型別。傳回表示連結的 IReference 物件。 (以 UmlExtensions 定義。)
公用擴充方法 ApplyStereotype 將造型套用於元素。建立以造型代表模型項目擴充的 IStereotypeInstance。 (以 ProfileStereotypeExtensions 定義。)
公用擴充方法 Delete 刪除此項目和任何關聯性、擁有的元素,以及圖形。 (以 UmlExtensions 定義。)
公用擴充方法 DeleteAllReference 移除指定標籤的所有參考。 (以 UmlExtensions 定義。)
公用擴充方法 GetId 取得可識別此元素的 GUID。 (以 UmlExtensions 定義。)
公用擴充方法 GetModelStore 取得包含此元素的 IModelStore。 (以 UmlExtensions 定義。)
公用擴充方法 GetReferences 取得予此元素相關聯之指定標記的 IReferences。 (以 UmlExtensions 定義。)
公用擴充方法 GetRelatedElements<T> 取得與此元素具有指定類型關聯性的元素。 (以 UmlExtensions 定義。)
公用擴充方法 GetRelatedLinks<T> 取得此項目與指定型別的關聯性。 (以 UmlExtensions 定義。)
公用擴充方法 Shapes 所有圖形,在任何開啟中的圖表或指定的開啟圖表顯示模型項目。 (以 PresentationHelpers 定義。)

回頁首

備註

注意事項注意事項

這個型別中定義的方法是擴充方法。若要使用方法,您必須將專案參考加入至 .NET 組件 Microsoft.VisualStudio.ArchitectureTools.Extensibility.dll,而且必須將指示詞 using Microsoft.VisualStudio.ArchitectureTools.Extensibility.Uml; 包含在程式碼中。

請參閱

參考

Microsoft.VisualStudio.Uml.Classes 命名空間