Class Class
Represents a group of instances with common properties like attributes or references
[XmlNamespace("http://nmf.codeplex.com/nmeta/")]
[XmlNamespacePrefix("nmeta")]
[ModelRepresentationClass("http://nmf.codeplex.com/nmeta/#//Class")]
public class Class : ReferenceType, IClass, IReferenceType, IStructuredType, IType, IMetaElement, IModelElement, INotifyPropertyChanged, INotifyPropertyChanging
- Inheritance
-
Class
- Implements
- Inherited Members
- Extension Methods
Constructors
Class()
Creates a new instance
public Class()
Properties
AttributeConstraints
The AttributeConstraints property
[Browsable(false)]
[XmlAttribute(false)]
[Containment]
[XmlOpposite("DeclaringType")]
public ICollectionExpression<IAttributeConstraint> AttributeConstraints { get; }
Property Value
BaseTypes
The BaseTypes property
[XmlAttribute(true)]
public ICollectionExpression<IClass> BaseTypes { get; }
Property Value
Children
Gets the child model elements of this model element
public override IEnumerableExpression<IModelElement> Children { get; }
Property Value
ClassInstance
Gets the Class model for this type
public static IClass ClassInstance { get; }
Property Value
Identifier
Gets or sets the attribute that will identify instances of this class
[XmlAttribute(true)]
public IAttribute Identifier { get; set; }
Property Value
IdentifierScope
Specifies whether the identifier is valid only in the scope of its container or on a global scope.
[XmlAttribute(true)]
public IdentifierScope IdentifierScope { get; set; }
Property Value
Remarks
This attribute is ignored when this class is not identified.
InstanceOf
The InstanceOf property
[XmlAttribute(true)]
public IClass InstanceOf { get; set; }
Property Value
IsAbstract
The IsAbstract property
[TypeConverter(typeof(LowercaseBooleanConverter))]
[XmlAttribute(true)]
public bool IsAbstract { get; set; }
Property Value
ReferenceConstraints
The ReferenceConstraints property
[Browsable(false)]
[XmlAttribute(false)]
[Containment]
[XmlOpposite("DeclaringType")]
public ICollectionExpression<IReferenceConstraint> ReferenceConstraints { get; }
Property Value
ReferencedElements
Gets the referenced model elements of this model element
public override IEnumerableExpression<IModelElement> ReferencedElements { get; }
Property Value
Methods
GetAttributeValue(string, int)
Resolves the given attribute name
protected override object GetAttributeValue(string attribute, int index)
Parameters
Returns
- object
The attribute value or null if it could not be found
GetClass()
Gets the Class for this model element
public override IClass GetClass()
Returns
GetCollectionForFeature(string)
Gets the Model element collection for the given feature
protected override IList GetCollectionForFeature(string feature)
Parameters
feature
stringThe requested feature
Returns
- IList
A non-generic list of elements
GetCompositionName(object)
Gets the property name for the given container
protected override string GetCompositionName(object container)
Parameters
container
objectThe container object
Returns
- string
The name of the respective container reference
GetExpressionForAttribute(string)
Gets the property expression for the given attribute
protected override INotifyExpression<object> GetExpressionForAttribute(string attribute)
Parameters
attribute
stringThe requested attribute in upper case
Returns
- INotifyExpression<object>
An incremental property expression
GetExpressionForReference(string)
Gets the property expression for the given reference
protected override INotifyExpression<IModelElement> GetExpressionForReference(string reference)
Parameters
reference
stringThe requested reference in upper case
Returns
- INotifyExpression<IModelElement>
An incremental property expression
GetModelElementForReference(string, int)
Resolves the given URI to a child model element
protected override IModelElement GetModelElementForReference(string reference, int index)
Parameters
Returns
- IModelElement
The model element or null if it could not be found
OnIdentifierChanged(ValueChangedEventArgs)
Raises the IdentifierChanged event
protected virtual void OnIdentifierChanged(ValueChangedEventArgs eventArgs)
Parameters
eventArgs
ValueChangedEventArgsThe event data
OnIdentifierChanging(ValueChangedEventArgs)
Raises the IdentifierChanging event
protected virtual void OnIdentifierChanging(ValueChangedEventArgs eventArgs)
Parameters
eventArgs
ValueChangedEventArgsThe event data
OnIdentifierScopeChanged(ValueChangedEventArgs)
Raises the IdentifierScopeChanged event
protected virtual void OnIdentifierScopeChanged(ValueChangedEventArgs eventArgs)
Parameters
eventArgs
ValueChangedEventArgsThe event data
OnIdentifierScopeChanging(ValueChangedEventArgs)
Raises the IdentifierScopeChanging event
protected virtual void OnIdentifierScopeChanging(ValueChangedEventArgs eventArgs)
Parameters
eventArgs
ValueChangedEventArgsThe event data
OnInstanceOfChanged(ValueChangedEventArgs)
Raises the InstanceOfChanged event
protected virtual void OnInstanceOfChanged(ValueChangedEventArgs eventArgs)
Parameters
eventArgs
ValueChangedEventArgsThe event data
OnInstanceOfChanging(ValueChangedEventArgs)
Raises the InstanceOfChanging event
protected virtual void OnInstanceOfChanging(ValueChangedEventArgs eventArgs)
Parameters
eventArgs
ValueChangedEventArgsThe event data
OnIsAbstractChanged(ValueChangedEventArgs)
Raises the IsAbstractChanged event
protected virtual void OnIsAbstractChanged(ValueChangedEventArgs eventArgs)
Parameters
eventArgs
ValueChangedEventArgsThe event data
OnIsAbstractChanging(ValueChangedEventArgs)
Raises the IsAbstractChanging event
protected virtual void OnIsAbstractChanging(ValueChangedEventArgs eventArgs)
Parameters
eventArgs
ValueChangedEventArgsThe event data
SetFeature(string, object)
Sets a value to the given feature
protected override void SetFeature(string feature, object value)
Parameters
Events
IdentifierChanged
Gets fired when the Identifier property changed its value
public event EventHandler<ValueChangedEventArgs> IdentifierChanged
Event Type
IdentifierChanging
Gets fired before the Identifier property changes its value
public event EventHandler<ValueChangedEventArgs> IdentifierChanging
Event Type
IdentifierScopeChanged
Gets fired when the IdentifierScope property changed its value
public event EventHandler<ValueChangedEventArgs> IdentifierScopeChanged
Event Type
IdentifierScopeChanging
Gets fired before the IdentifierScope property changes its value
public event EventHandler<ValueChangedEventArgs> IdentifierScopeChanging
Event Type
InstanceOfChanged
Gets fired when the InstanceOf property changed its value
public event EventHandler<ValueChangedEventArgs> InstanceOfChanged
Event Type
InstanceOfChanging
Gets fired before the InstanceOf property changes its value
public event EventHandler<ValueChangedEventArgs> InstanceOfChanging
Event Type
IsAbstractChanged
Gets fired when the IsAbstract property changed its value
public event EventHandler<ValueChangedEventArgs> IsAbstractChanged
Event Type
IsAbstractChanging
Gets fired before the IsAbstract property changes its value
public event EventHandler<ValueChangedEventArgs> IsAbstractChanging