• Skip to content
  • Skip to link menu
KDE 4.0 API Reference
  • KDE API Reference
  • kdesdk
  • Sitemap
  • Contact Us
 

umbrello/umbrello

UMLAttribute Class Reference

#include <attribute.h>

Inheritance diagram for UMLAttribute:

Inheritance graph
[legend]

List of all members.


Detailed Description

This class is used to set up information for an attribute.

This is like a programming attribute. It has a type, name, visibility and initial value.

Sets up attribute information.

Author:
Paul Hensgen <phensgen@techie.com>
See also:
UMLObject Bugs and comments to uml-devel@lists.sf.net or http://bugs.kde.org

Definition at line 28 of file attribute.h.


Signals

void attributeChanged ()

Public Member Functions

 UMLAttribute (UMLObject *parent, const QString &name, Uml::IDType id=Uml::id_None, Uml::Visibility s=Uml::Visibility::Private, UMLObject *type=0, const QString &iv=0)
 UMLAttribute (UMLObject *parent)
bool operator== (const UMLAttribute &rhs)
virtual ~UMLAttribute ()
virtual void copyInto (UMLObject *lhs) const
void setName (const QString &name)
void setVisibility (Uml::Visibility s)
virtual UMLObject * clone () const
QString getInitialValue ()
void setInitialValue (const QString &iv)
QString toString (Uml::Signature_Type sig=Uml::st_NoSig)
QString getFullyQualifiedName (const QString &separator=QString(), bool includeRoot=false) const
void saveToXMI (QDomDocument &qDoc, QDomElement &qElement)
virtual bool showPropertiesDialog (QWidget *parent)
void setParmKind (Uml::Parameter_Direction pk)
Uml::Parameter_Direction getParmKind () const
virtual UMLClassifierList getTemplateParams ()

Protected Member Functions

bool load (QDomElement &element)

Protected Attributes

QString m_InitialValue
Uml::Parameter_Direction m_ParmKind

Constructor & Destructor Documentation

UMLAttribute::UMLAttribute ( UMLObject *  parent,
const QString &  name,
Uml::IDType  id = Uml::id_None,
Uml::Visibility  s = Uml::Visibility::Private,
UMLObject *  type = 0,
const QString &  iv = 0 
)

Sets up an attribute.

Parameters:
parent The parent of this UMLAttribute.
name The name of this UMLAttribute.
id The unique id given to this UMLAttribute.
s The visibility of the UMLAttribute.
type The type of this UMLAttribute.
iv The initial value of the attribute.

Definition at line 25 of file attribute.cpp.

UMLAttribute::UMLAttribute ( UMLObject *  parent  ) 

Sets up an attribute.

Parameters:
parent The parent of this UMLAttribute.

Definition at line 42 of file attribute.cpp.

UMLAttribute::~UMLAttribute (  )  [virtual]

destructor.

Definition at line 48 of file attribute.cpp.


Member Function Documentation

bool UMLAttribute::operator== ( const UMLAttribute &  rhs  ) 

Overloaded '==' operator.

Definition at line 151 of file attribute.cpp.

void UMLAttribute::copyInto ( UMLObject *  lhs  )  const [virtual]

Copy the internal presentation of this object into the UMLAttribute object.

Reimplemented from UMLClassifierListItem.

Reimplemented in UMLEntityAttribute.

Definition at line 166 of file attribute.cpp.

void UMLAttribute::setName ( const QString &  name  )  [virtual]

Reimplementation of method from UMLObject is required as an extra signal, attributeChanged(), is emitted.

Reimplemented from UMLObject.

Definition at line 50 of file attribute.cpp.

void UMLAttribute::setVisibility ( Uml::Visibility  s  )  [virtual]

Reimplementation of method from UMLObject is required as an extra signal, attributeChanged(), is emitted.

Reimplemented from UMLObject.

Definition at line 56 of file attribute.cpp.

UMLObject * UMLAttribute::clone (  )  const [virtual]

Make a clone of the UMLAttribute.

Implements UMLClassifierListItem.

Reimplemented in UMLEntityAttribute.

Definition at line 179 of file attribute.cpp.

QString UMLAttribute::getInitialValue (  ) 

Returns The initial value of the UMLAttribute.

Returns:
The initial value of the Atrtibute.

Definition at line 62 of file attribute.cpp.

void UMLAttribute::setInitialValue ( const QString &  iv  ) 

Sets the initial value of the UMLAttribute.

Parameters:
iv The initial value of the UMLAttribute.

Definition at line 66 of file attribute.cpp.

QString UMLAttribute::toString ( Uml::Signature_Type  sig = Uml::st_NoSig  )  [virtual]

Returns a string representation of the UMLAttribute.

Parameters:
sig If true will show the attribute type and initial value.
Returns:
Returns a string representation of the UMLAttribute.

Reimplemented from UMLClassifierListItem.

Reimplemented in UMLEntityAttribute.

Definition at line 81 of file attribute.cpp.

QString UMLAttribute::getFullyQualifiedName ( const QString &  separator = QString(),
bool  includeRoot = false 
) const [virtual]

Reimplement method from UMLObject.

Reimplemented from UMLObject.

Definition at line 127 of file attribute.cpp.

void UMLAttribute::saveToXMI ( QDomDocument &  qDoc,
QDomElement &  qElement 
) [virtual]

Creates the <UML:Attribute> XMI element.

Implements UMLObject.

Reimplemented in UMLEntityAttribute.

Definition at line 189 of file attribute.cpp.

bool UMLAttribute::showPropertiesDialog ( QWidget *  parent  )  [virtual]

Display the properties configuration dialog for the attribute.

Implements UMLClassifierListItem.

Reimplemented in UMLEntityAttribute.

Definition at line 248 of file attribute.cpp.

void UMLAttribute::setParmKind ( Uml::Parameter_Direction  pk  ) 

Definition at line 73 of file attribute.cpp.

Uml::Parameter_Direction UMLAttribute::getParmKind (  )  const

Definition at line 77 of file attribute.cpp.

UMLClassifierList UMLAttribute::getTemplateParams (  )  [virtual]

Returns all the template params (if any) that are in the type of this attribute.

Definition at line 303 of file attribute.cpp.

void UMLAttribute::attributeChanged (  )  [signal]

Required for informing AssociationWidgets representing this attribute that the attribute name or visibility has changed.

bool UMLAttribute::load ( QDomElement &  element  )  [protected, virtual]

Loads the <UML:Attribute> XMI element.

Reimplemented from UMLObject.

Reimplemented in UMLEntityAttribute.

Definition at line 202 of file attribute.cpp.


Member Data Documentation

QString UMLAttribute::m_InitialValue [protected]

text for the attribute's initial value.

Definition at line 146 of file attribute.h.

Uml::Parameter_Direction UMLAttribute::m_ParmKind [protected]

Definition at line 147 of file attribute.h.


The documentation for this class was generated from the following files:
  • attribute.h
  • attribute.cpp

umbrello/umbrello

Skip menu "umbrello/umbrello"
  • Main Page
  • Modules
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

kdesdk

Skip menu "kdesdk"
  • kate
  •     kate
  • umbrello
  •   umbrello
Generated for kdesdk by doxygen 1.5.4
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal