mdg.parse package¶
Submodules¶
mdg.parse.bouml_xmi module¶
-
mdg.parse.bouml_xmi.
model_package_parse_inheritance
(package)[source]¶ Looks for classes which are specializations of a supertype and finds the correct object
-
mdg.parse.bouml_xmi.
package_parse
(element, root_element, parent_package)[source]¶ Extract package details, call class parser for classes and self parser for sub-packages. Associations are not done here, but in a 2nd pass using the parse_associations function. :param element: :param root_element: :return: :rtype: UMLPackage
-
mdg.parse.bouml_xmi.
package_parse_associations
(package, element, root_element)[source]¶ Packages and classes should already have been parsed so now we link classes for each association. This gets messy as XMI output varies based on association type. This supports both un-specified and source to destination directional associations :param root_element: :param element: XML Element :type package: UMLPackage
-
mdg.parse.bouml_xmi.
parse_test_cases
(package) → List[mdg.uml.UMLInstance][source]¶ Looks through package hierarchy for instances with request or response stereotype and returns list of instances. :rtype: list<UMLInstance>
mdg.parse.drawio_xml module¶
-
mdg.parse.drawio_xml.
attr_parse
(parent: mdg.uml.UMLClass, element, root, stereotypes) → mdg.uml.UMLAttribute[source]¶
-
mdg.parse.drawio_xml.
class_parse
(package: mdg.uml.UMLPackage, element, root) → mdg.uml.UMLClass[source]¶
-
mdg.parse.drawio_xml.
enumeration_parse
(package: mdg.uml.UMLPackage, element, root) → mdg.uml.UMLEnumeration[source]¶
-
mdg.parse.drawio_xml.
package_parse
(element, root_element, parent_package: Optional[mdg.uml.UMLPackage]) → mdg.uml.UMLPackage[source]¶ Extract package details, call class parser for classes and self parser for sub-packages. Association linking is not done here, but in a 2nd pass using the parse_associations function.
mdg.parse.sparx_db module¶
-
mdg.parse.sparx_db.
association_parse
(session, tconnector: mdg.parse.sparx_db_models.TConnector, package: mdg.uml.UMLPackage, source: Union[mdg.uml.UMLClass, mdg.uml.UMLInstance], dest: Union[mdg.uml.UMLClass, mdg.uml.UMLInstance])[source]¶
-
mdg.parse.sparx_db.
attr_parse
(session, parent: mdg.uml.UMLClass, tattribute: mdg.parse.sparx_db_models.TAttribute)[source]¶
-
mdg.parse.sparx_db.
class_parse
(session, package: mdg.uml.UMLPackage, tobject: mdg.parse.sparx_db_models.TObject)[source]¶
-
mdg.parse.sparx_db.
enumeration_parse
(session, package: mdg.uml.UMLPackage, tobject: mdg.parse.sparx_db_models.TObject)[source]¶
-
mdg.parse.sparx_db.
instance_parse
(session, package: mdg.uml.UMLPackage, tobject: mdg.parse.sparx_db_models.TObject)[source]¶
-
mdg.parse.sparx_db.
package_parse
(session, tpackage: mdg.parse.sparx_db_models.TPackage, parent_package: Optional[mdg.uml.UMLPackage])[source]¶ Extract package details, call class parser for classes and self parser for sub-packages. Associations are not done here, but in a 2nd pass using the parse_associations function. :param element: :param root_element: :return: :rtype: UMLPackage
-
mdg.parse.sparx_db.
package_parse_associations
(session, package: mdg.uml.UMLPackage)[source]¶ Packages and classes should already have been parsed so now we link classes for each association.
-
mdg.parse.sparx_db.
parse_test_cases
(package: mdg.uml.UMLPackage) → List[mdg.uml.UMLInstance][source]¶ Looks through package hierarchy for instances with request or response stereotype and returns list of instances.
mdg.parse.sparx_db_models module¶
-
class
mdg.parse.sparx_db_models.
TAttribute
(**kwargs)[source]¶ Bases:
sqlalchemy.orm.decl_api.Base
-
Default
¶
-
allowduplicates
¶
-
classifier
¶
-
const
¶
-
container
¶
-
containment
¶
-
derived
¶
-
ea_guid
¶
-
genoption
¶
-
id
¶
-
iscollection
¶
-
isordered
¶
-
isstatic
¶
-
length
¶
-
lowerbound
¶
-
name
¶
-
notes
¶
-
object_id
¶
-
pos
¶
-
precision
¶
-
scale
¶
-
scope
¶
-
stereotype
¶
-
style
¶
-
styleex
¶
-
type
¶
-
upperbound
¶
-
-
class
mdg.parse.sparx_db_models.
TAttributeconstraint
(**kwargs)[source]¶ Bases:
sqlalchemy.orm.decl_api.Base
-
Constraint
¶
-
attname
¶
-
id
¶
-
notes
¶
-
object_id
¶
-
type
¶
-
-
class
mdg.parse.sparx_db_models.
TConnector
(**kwargs)[source]¶ Bases:
sqlalchemy.orm.decl_api.Base
-
actionflags
¶
-
btm_end_label
¶
-
btm_mid_label
¶
-
btm_start_label
¶
-
connector_id
¶
-
connector_type
¶
-
destaccess
¶
-
destcard
¶
-
destchangeable
¶
-
destconstraint
¶
-
destcontainment
¶
-
destelement
¶
-
destisaggregate
¶
-
destisordered
¶
-
destqualifier
¶
-
destrole
¶
-
destrolenote
¶
-
destroletype
¶
-
deststereotype
¶
-
deststyle
¶
-
destts
¶
-
diagramid
¶
-
direction
¶
-
dispatchaction
¶
-
ea_guid
¶
-
end_edge
¶
-
end_object_id
¶
-
eventflags
¶
-
headstyle
¶
-
isbold
¶
-
isleaf
¶
-
isroot
¶
-
issignal
¶
-
isspec
¶
-
isstimulus
¶
-
linecolor
¶
-
linestyle
¶
-
linkaccess
¶
-
name
¶
-
notes
¶
-
pdata1
¶
-
pdata2
¶
-
pdata3
¶
-
pdata4
¶
-
pdata5
¶
-
ptendx
¶
-
ptendy
¶
-
ptstartx
¶
-
ptstarty
¶
-
routestyle
¶
-
seqno
¶
-
sourceaccess
¶
-
sourcecard
¶
-
sourcechangeable
¶
-
sourceconstraint
¶
-
sourcecontainment
¶
-
sourceelement
¶
-
sourceisaggregate
¶
-
sourceisordered
¶
-
sourcequalifier
¶
-
sourcerole
¶
-
sourcerolenote
¶
-
sourceroletype
¶
-
sourcestereotype
¶
-
sourcestyle
¶
-
sourcets
¶
-
start_edge
¶
-
start_object_id
¶
-
stateflags
¶
-
stereotype
¶
-
styleex
¶
-
subtype
¶
-
target2
¶
-
top_end_label
¶
-
top_mid_label
¶
-
top_start_label
¶
-
virtualinheritance
¶
-
-
class
mdg.parse.sparx_db_models.
TObject
(**kwargs)[source]¶ Bases:
sqlalchemy.orm.decl_api.Base
-
abstract
¶
-
actionflags
¶
-
alias
¶
-
backcolor
¶
-
bordercolor
¶
-
borderstyle
¶
-
borderwidth
¶
-
cardinality
¶
-
classifier
¶
-
classifier_guid
¶
-
complexity
¶
-
concurrency
¶
-
createddate
¶
-
diagram_id
¶
-
ea_guid
¶
-
effort
¶
-
eventflags
¶
-
fontcolor
¶
-
genfile
¶
-
genlinks
¶
-
genoption
¶
-
gentype
¶
-
header1
¶
-
header2
¶
-
isactive
¶
-
isleaf
¶
-
isroot
¶
-
isspec
¶
-
modifieddate
¶
-
multiplicity
¶
-
name
¶
-
note
¶
-
ntype
¶
-
object_id
¶
-
object_type
¶
-
package_id
¶
-
packageflags
¶
-
parentid
¶
-
pdata1
¶
-
pdata2
¶
-
pdata3
¶
-
pdata4
¶
-
pdata5
¶
-
persistence
¶
-
phase
¶
-
runstate
¶
-
scope
¶
-
stateflags
¶
-
status
¶
-
stereotype
¶
-
style
¶
-
styleex
¶
-
tagged
¶
-
tpos
¶
-
version
¶
-
visibility
¶
-
-
class
mdg.parse.sparx_db_models.
TPackage
(**kwargs)[source]¶ Bases:
sqlalchemy.orm.decl_api.Base
-
batchload
¶
-
batchsave
¶
-
codepath
¶
-
createddate
¶
-
ea_guid
¶
-
iscontrolled
¶
-
lastloaddate
¶
-
lastsavedate
¶
-
logxml
¶
-
modifieddate
¶
-
name
¶
-
namespace
¶
-
notes
¶
-
package_id
¶
-
packageflags
¶
-
parent_id
¶
-
pkgowner
¶
-
protected
¶
-
tpos
¶
-
umlversion
¶
-
usedtd
¶
-
version
¶
-
xmlpath
¶
-
mdg.parse.sparx_xmi module¶
-
mdg.parse.sparx_xmi.
attr_parse
(parent: Union[mdg.uml.UMLClass, mdg.uml.UMLEnumeration, mdg.uml.UMLComponent], element, root)[source]¶
-
mdg.parse.sparx_xmi.
model_package_parse_inheritance
(package)[source]¶ Looks for classes which are specializations of a supertype and finds the correct object
-
mdg.parse.sparx_xmi.
package_parse
(element, root_element, parent_package)[source]¶ Extract package details, call class parser for classes and self parser for sub-packages. Associations are not done here, but in a 2nd pass using the parse_associations function. :param element: :param root_element: :return: :rtype: UMLPackage
-
mdg.parse.sparx_xmi.
package_parse_associations
(package, element, root_element)[source]¶ Packages and classes should already have been parsed so now we link classes for each association. This gets messy as XMI output varies based on association type. This supports both un-specified and source to destination directional associations :param root_element: :param element: XML Element :type package: UMLPackage
-
mdg.parse.sparx_xmi.
parse_test_cases
(package) → List[mdg.uml.UMLInstance][source]¶ Looks through package hierarchy for instances with request or response stereotype and returns list of instances. :rtype: list<UMLInstance>