Appendix B. Known Kermeta tags

[Warning]Text not verified for kermeta 2

This annex collect the use of known tags. They are generally used as an extension on Kermeta in these typically uses :

[Note]Note

TODO : finish this by looking into kermeta2ecore transformation

Kown tags :

aspect

Possible values.  "true", case insensitive, any other value is considered as "false".

Context.  Class

Use description.  Old way to indicate that a Class must be reopened as an aspect of another Class and then merging its features. We now prefer to use the dedicated keyword.

Use sample. 

@aspect "true"
class MyClas {
// ...
}

ecoreUri

Possible values.  An nsURI.

Context.  Package

Use description.  Indicates the nsUri for the given package when it is transformed in Ecore.

Use sample. 

@ecoreUri "http://myPackage/1.0/"
package myPackage;

mainClass

Possible values.  Qualified name of a class in the Kermeta program.

Context.  ModelingUnit

Use description.  Indicates a preferred class from which the run configuration should try to start the Kermeta program. This helps to create a default run configuration. Must be used with the mainOperation tag.

Use sample. 

@mainClass "myPackage::MyMainClass"
@mainOperation "main"

package myPackage;

require kermeta
class MyMainClass
{
	operation main() : Void is do 
		// TODO: implement 'main' operation
	end
}

mainOperation

Possible values.  name of an operation in the main class.

Context.  ModelingUnit

Use description.  Indicates a preferred operation from which the run configuration should try to start the Kermeta program. This helps to create a default run configuration. Must be used with the mainClass tag. The operation must : either have no parameter, or have string parameters.

Use sample. 

@mainClass "myPackage::MyMainClass"
@mainOperation "main"

package myPackage;

require kermeta
class MyMainClass
{
	operation main() : Void is do 
		// TODO: implement 'main' operation
	end
}