Class Meta2ClassesTransformation.RefinedAttributeCollectionClassGenerator
The transformation rule that generates a collection class for a refined attribute
Inheritance
Inherited Members
Namespace: NMF.Models.Meta
Assembly: NMF.Models.MetaTransformation.dll
Syntax
public class Meta2ClassesTransformation.RefinedAttributeCollectionClassGenerator : TransformationRule<IClass, IAttribute, CodeTypeDeclaration>
Methods
| Edit this page View SourceCreateOutput(IClass, IAttribute, ITransformationContext)
Creates the uninitialized transformation rule output
Declaration
public override CodeTypeDeclaration CreateOutput(IClass scope, IAttribute attribute, ITransformationContext context)
Parameters
Type | Name | Description |
---|---|---|
IClass | scope | The scope in which the attribute is refined |
IAttribute | attribute | The refined attribute |
ITransformationContext | context | The transformation context |
Returns
Type | Description |
---|---|
CodeTypeDeclaration | The uninitialized code type declaration |
Overrides
ImplementCollection(CodeTypeDeclaration, CodeTypeReference, CodeExpression, List<IAttribute>, List<string>, ITransformationContext)
Implements the ICollection interface
Declaration
protected virtual void ImplementCollection(CodeTypeDeclaration generatedType, CodeTypeReference elementType, CodeExpression standardValuesRef, List<IAttribute> implementingAttributes, List<string> constraintValues, ITransformationContext context)
Parameters
Type | Name | Description |
---|---|---|
CodeTypeDeclaration | generatedType | The generated code type declaration |
CodeTypeReference | elementType | The element type reference |
CodeExpression | standardValuesRef | A reference to the standard values field |
List<IAttribute> | implementingAttributes | The attributes implementing the collection |
List<string> | constraintValues | The constraints that apply to the reference |
ITransformationContext | context | The context in which the collection is implemented |
ImplementList(CodeTypeDeclaration, CodeTypeReference, CodeExpression, List<IAttribute>, List<string>, ITransformationContext)
Implements the IList interface
Declaration
protected virtual void ImplementList(CodeTypeDeclaration generatedType, CodeTypeReference elementType, CodeExpression standardValuesRef, List<IAttribute> implementingAttributes, List<string> constraintValues, ITransformationContext context)
Parameters
Type | Name | Description |
---|---|---|
CodeTypeDeclaration | generatedType | The generated code type declaration |
CodeTypeReference | elementType | The element tyoe reference |
CodeExpression | standardValuesRef | A reference to the standard values field |
List<IAttribute> | implementingAttributes | The attributes implementing the collection |
List<string> | constraintValues | The constraints that apply to the attribute |
ITransformationContext | context | The context in which the collection is implemented |
ImplementNotifiable(CodeTypeDeclaration, CodeTypeReference)
Implement the IEnumerableExpression interface
Declaration
protected virtual void ImplementNotifiable(CodeTypeDeclaration generatedType, CodeTypeReference elementType)
Parameters
Type | Name | Description |
---|---|---|
CodeTypeDeclaration | generatedType | The generated code type declaration |
CodeTypeReference | elementType | The element type reference |
ImplementNotifications(CodeTypeDeclaration, List<IAttribute>, CodeConstructor, CodeArgumentReferenceExpression, ITransformationContext)
Implement notifications on the given generated type
Declaration
protected virtual void ImplementNotifications(CodeTypeDeclaration generatedType, List<IAttribute> implementingAttributes, CodeConstructor constructor, CodeArgumentReferenceExpression constrParentRef, ITransformationContext context)
Parameters
Type | Name | Description |
---|---|---|
CodeTypeDeclaration | generatedType | The generated type |
List<IAttribute> | implementingAttributes | The attributes that implemented the refined attribute |
CodeConstructor | constructor | The constructor of the class |
CodeArgumentReferenceExpression | constrParentRef | The parent of the attribute collection class |
ITransformationContext | context | The context in which the request is made |
Transform(IClass, IAttribute, CodeTypeDeclaration, ITransformationContext)
Initializes the generated collection class for the refined attribute
Declaration
public override void Transform(IClass scope, IAttribute attribute, CodeTypeDeclaration generatedType, ITransformationContext context)
Parameters
Type | Name | Description |
---|---|---|
IClass | scope | The scope in which the attribute is refined |
IAttribute | attribute | The attribute that is refined |
CodeTypeDeclaration | generatedType | The generated code declaration |
ITransformationContext | context | The transformation context |