# The short name of the class
# In Nit, the name of a class cannot evolve in refinements
- var name: String
+ redef var name: String
# The canonical name of the class
# Example: `"owner::module::MyClass"`
self.to_s = "{mmodule}#{mclass}"
end
+ # Actually the name of the `mclass`
+ redef fun name do return mclass.name
+
# All declared super-types
# FIXME: quite ugly but not better idea yet
var supertypes: Array[MClassType] = new Array[MClassType]
var intro_mclassdef: MClassDef
# The (short) name of the property
- var name: String
+ redef var name: String
# The canonical name of the property
# Example: "owner::my_module::MyClass::my_method"
self.to_s = "{mclassdef}#{mproperty}"
end
+ # Actually the name of the `mproperty`
+ redef fun name do return mproperty.name
+
# Internal name combining the module, the class and the property
# Example: "mymodule#MyClass#mymethod"
redef var to_s: String
# A named and possibly documented entity in the model.
# This class is usefull to generalize presentation of entities to the human.
abstract class MEntity
+ # The short (unqualified) name of this model entity
+ fun name: String is abstract
end
# A visibility (for modules, class and properties)
super MEntity
# The name of the project
- var name: String
+ redef var name: String
# The model of the project
var model: Model
# The name of the group
# empty name for a default group in a single-module project
- var name: String
+ redef var name: String
# The englobing project
var mproject: MProject