umbrello/umbrello
association.cpp
Go to the documentation of this file.
277 if (UMLDoc::tagEq(tag, "child") || UMLDoc::tagEq(tag, "subtype") || UMLDoc::tagEq(tag, "client")) {
358 if (m_AssocType == Uml::AssociationType::Association && getObjectId(RoleType::A) == getObjectId(RoleType::B))
691 void UMLAssociation::init(Uml::AssociationType::Enum type, UMLObject *roleAObj, UMLObject *roleBObj)
bool getOldLoadMode() const
Return the backward compatibility flag for loading files.
Definition: association.cpp:580
UMLObject * getObject(Uml::RoleType::Enum role) const
Returns the UMLObject assigned to the given role.
Definition: association.cpp:476
QString toString() const
Returns a String representation of this UMLAssociation.
Definition: association.cpp:111
Uml::ID::Type getRoleId(Uml::RoleType::Enum role) const
Returns the ID of the UMLObject assigned to the given role.
Definition: association.cpp:510
QString multiplicity() const
Returns the multiplicity assigned to the role.
Definition: umlrole.cpp:96
virtual bool loadFromXMI(QDomElement &element)
This method loads the generic parts of the XMI common to most model classes.
Definition: umlobject.cpp:914
void setAssociationType(Uml::AssociationType::Enum assocType)
Sets the assocType of the UMLAssociation.
Definition: association.cpp:589
Definition: basictypes.h:209
Uml::Visibility::Enum visibility() const
Returns the visibility of the object.
Definition: umlobject.cpp:435
static bool tagEq(const QString &tag, const QString &pattern)
Function for comparing tags in XMI files.
Definition: umldoc.cpp:3030
void setRoleDoc(const QString &doc, Uml::RoleType::Enum role)
Sets the documentation on the given role in the association.
Definition: association.cpp:659
void setVisibility(Uml::Visibility::Enum visibility)
Sets the visibility of the object.
Definition: umlobject.cpp:445
void setObject(UMLObject *obj)
Sets the UMLObject playing the role in the association.
Definition: umlrole.cpp:106
Definition: basictypes.h:210
QString toStringI18n(Enum item)
Converts a AssociationType to its string representation.
Definition: basictypes.cpp:323
UMLDoc * document() const
Returns a pointer to the current document connected to the KMainWindow instance.
Definition: uml.cpp:872
void setChangeability(Uml::Changeability::Enum value, Uml::RoleType::Enum role)
Sets the changeability of the given role of the UMLAssociation.
Definition: association.cpp:628
Uml::ModelType::Enum convert_OT_MT(UMLObject::ObjectType ot)
Return the Model_Type which corresponds to the given ObjectType.
Definition: model_utils.cpp:1602
void setMultiplicity(const QString &multi, Uml::RoleType::Enum role)
Sets the multiplicity of the given role of the UMLAssociation.
Definition: association.cpp:638
Definition: basictypes.h:102
This class contains the non-graphic representation of an association.
Definition: association.h:32
void setChangeability(Uml::Changeability::Enum value)
Sets the changeability of the role.
Definition: umlrole.cpp:128
void setObject(UMLObject *obj, Uml::RoleType::Enum role)
Sets the UMLObject playing the given role in the association.
Definition: association.cpp:608
virtual bool resolveRef()
Resolve referenced objects (if any.) Needs to be called after all UML objects are loaded from file...
Definition: umlobject.cpp:709
UMLAssociation(Uml::AssociationType::Enum type, UMLObject *roleA, UMLObject *roleB)
Sets up an association.
Definition: association.cpp:42
Enum fromInt(int item)
Convert a integer item into Changeability representation.
Definition: basictypes.cpp:639
void executeCommand(QUndoCommand *cmd)
Execute a command and pushit in the stack.
Definition: uml.cpp:3077
Uml::AssociationType::Enum getAssocType() const
Returns the AssociationType::Enum of the UMLAssociation.
Definition: association.cpp:103
Uml::Changeability::Enum changeability(Uml::RoleType::Enum role) const
Returns the changeability.
Definition: association.cpp:518
void setOldLoadMode(bool value=true)
Set the attribute m_bOldLoadMode.
Definition: association.cpp:572
Enum fromInt(int item)
Convert a integer item into ProgrammingLanguage representation.
Definition: basictypes.cpp:429
UMLRole * getUMLRole(Uml::RoleType::Enum role) const
Get the underlying UMLRole object for the given role.
Definition: association.cpp:563
bool isCommonXMIAttribute(const QString &tag)
Return true if the given tag is a one of the common XMI attributes, such as: "name" | "visibility" | ...
Definition: model_utils.cpp:503
bool load(QDomElement &element)
Creates the or XMI element including its role objects...
Definition: association.cpp:209
Definition: umlobject.h:53
UMLObject * findObjectById(Uml::ID::Type id)
Used to find a reference to a UMLObject by its ID.
Definition: umldoc.cpp:766
Definition: umlobject.h:57
QDomElement save(const QString &tag, QDomDocument &qDoc)
Auxiliary to saveToXMI.
Definition: umlobject.cpp:808
void saveToXMI(QDomDocument &qDoc, QDomElement &qElement)
Creates the or XMI element including its role objects...
Definition: association.cpp:158
QString toString(Enum item)
Convert ModelType item into QString representation.
Definition: basictypes.cpp:39
This class contains the non-graphic representation of an association role.
Definition: umlrole.h:24
Definition: basictypes.h:120
bool operator==(const UMLAssociation &rhs) const
Overloaded '==' operator.
Definition: association.cpp:87
Uml::Changeability::Enum changeability() const
Returns the Changeablity of the role.
Definition: umlrole.cpp:86
void setVisibility(Uml::Visibility::Enum value, Uml::RoleType::Enum role)
Sets the visibility of the given role of the UMLAssociation.
Definition: association.cpp:618
QString getRoleDoc(Uml::RoleType::Enum role) const
Returns the documentation assigned to the given role.
Definition: association.cpp:554
QString getRoleName(Uml::RoleType::Enum role) const
Returns the name assigned to the role A.
Definition: association.cpp:545
Uml::ID::Type getObjectId(Uml::RoleType::Enum role) const
Returns the ID of the UMLObject assigned to the given role.
Definition: association.cpp:488
void saveToXMI(QDomDocument &qDoc, QDomElement &qElement)
Creates the XMI element.
Definition: umlrole.cpp:160
void setRoleName(const QString &roleName, Uml::RoleType::Enum role)
Sets the name of the given role of the UMLAssociation.
Definition: association.cpp:649
QString getMultiplicity(Uml::RoleType::Enum role) const
Returns the multiplicity assigned to the given role.
Definition: association.cpp:536
void addAssocToConcepts(UMLAssociation *assoc)
Adds an existing association to the matching concept in the list of concepts.
Definition: package.cpp:80
UMLFolder * rootFolder(Uml::ModelType::Enum mt)
Return the predefined root folder of the given type.
Definition: umldoc.cpp:2676
Enum fromInt(int item)
Convert a integer item into RoleType representation.
Definition: basictypes.cpp:739
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 23:05:58 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 23:05:58 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.