nitc :: UMLModel :: _mainmodule
Main module used for linearization.nitc :: UMLModel :: defaultinit
nitc :: UMLModel :: generate_class_uml
Generates a UML class diagram from aModel
nitc :: UMLModel :: generate_package_uml
Generates a UML package diagram from aModel
nitc :: UMLModel :: mainmodule=
Main module used for linearization.nitc :: UMLModel :: _mainmodule
Main module used for linearization.core :: Object :: class_factory
Implementation used byget_class
to create the specific class.
nitc :: UMLModel :: defaultinit
core :: Object :: defaultinit
nitc :: UMLModel :: generate_class_uml
Generates a UML class diagram from aModel
nitc :: UMLModel :: generate_package_uml
Generates a UML package diagram from aModel
core :: Object :: is_same_instance
Return true ifself
and other
are the same instance (i.e. same identity).
core :: Object :: is_same_serialized
Isself
the same as other
in a serialization context?
core :: Object :: is_same_type
Return true ifself
and other
have the same dynamic type.
nitc :: UMLModel :: mainmodule=
Main module used for linearization.core :: Object :: native_class_name
The class name of the object in CString format.core :: Object :: output_class_name
Display class name on stdout (debug only).
# UML model builder.
class UMLModel
# Model to access mentities
var model: Model
# Main module used for linearization.
var mainmodule: MModule
# Filters to apply on model if any
var filter: nullable ModelFilter
end
src/uml/uml_base.nit:21,1--32,3
redef class UMLModel
# Generates a UML class diagram from a `Model`
fun generate_class_uml: Writable do
var tpl = new Template
tpl.add "digraph G \{\n"
tpl.add """ fontname = "Bitstream Vera Sans"
fontsize = 8
node [
fontname = "Bitstream Vera Sans"
fontsize = 8
shape = "record"
]
edge [
fontname = "Bitstream Vera Sans"
fontsize = 8
]\n"""
for mclass in model.collect_mclasses(filter) do
tpl.add mclass.tpl_class(self)
tpl.add "\n"
end
tpl.add "\}"
return tpl
end
end
src/uml/uml_class.nit:21,1--45,3
redef class UMLModel
# Generates a UML package diagram from a `Model`
fun generate_package_uml: Writable do
var tpl = new Template
tpl.add "digraph G \{\n"
tpl.add """ fontname = "Bitstream Vera Sans"
fontsize = 8
node [
fontname = "Bitstream Vera Sans"
fontsize = 8
shape = "record"
]
edge [
fontname = "Bitstream Vera Sans"
fontsize = 8
]\n"""
tpl.add mainmodule.tpl_module(self)
tpl.add "\}"
return tpl
end
end
src/uml/uml_module.nit:21,1--41,3