00001 /* 00002 * Copyright (C) 2004 Andrew Sutton 00003 * 00004 * This library is free software; you can redistribute it and/or 00005 * modify it under the terms of the GNU Lesser General Public 00006 * License as published by the Free Software Foundation; either 00007 * version 2.1 of the License, or (at your option) any later version. 00008 * 00009 * This library is distributed in the hope that it will be useful, 00010 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00011 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00012 * Lesser General Public License for more details. 00013 * 00014 * You should have received a copy of the GNU Lesser General Public 00015 * License along with this library; if not, write to: 00016 * 00017 * The Free Software Foundation, Inc. 00018 * 59 Temple Place, Suite 330 00019 * Boston, MA 02111-1307 USA 00020 * 00021 * Contact: 00022 * Andrew Sutton asutton@cs.kent.edu 00023 */ 00024 00025 #ifndef UML_ASSOCIATIONEND_HPP 00026 #define UML_ASSOCIATIONEND_HPP 00027 00028 #include <UML/ModelElement.hpp> 00029 #include <UML/OrderingKind.hpp> 00030 #include <UML/AggregationKind.hpp> 00031 #include <UML/ScopeKind.hpp> 00032 #include <UML/ChangeableKind.hpp> 00033 00034 namespace UML 00035 { 00036 // forward declarations 00037 class AssociationEnd; 00038 class AssociationEndImpl; 00039 class Multiplicity; 00040 class Association; 00041 class Attribute; 00042 class Classifier; 00043 class Classifier; 00044 00045 class AssociationEnd : virtual public UML::ModelElement 00046 { 00047 public: 00048 typedef OMF::BasicClass<AssociationEndImpl> Proxy; 00049 00050 AssociationEnd(); 00051 virtual ~AssociationEnd(); 00052 00053 const OMF::Boolean &isNavigable() const; 00054 void setIsNavigable(const OMF::Boolean &value); 00055 void clearIsNavigable(); 00056 00057 const OrderingKind &ordering() const; 00058 void setOrdering(const OrderingKind &value); 00059 void clearOrdering(); 00060 00061 const AggregationKind &aggregation() const; 00062 void setAggregation(const AggregationKind &value); 00063 void clearAggregation(); 00064 00065 const ScopeKind &targetScope() const; 00066 void setTargetScope(const ScopeKind &value); 00067 void clearTargetScope(); 00068 00069 Multiplicity *multiplicity(); 00070 void setMultiplicity(Multiplicity *value); 00071 void clearMultiplicity(); 00072 00073 const ChangeableKind &changeability() const; 00074 void setChangeability(const ChangeableKind &value); 00075 void clearChangeability(); 00076 00077 Association *association(); 00078 void setAssociation(Association *value); 00079 void clearAssociation(); 00080 00081 const OMF::Set &qualifier(); 00082 void addQualifier(Attribute *value); 00083 void removeQualifier(Attribute *value); 00084 void clearQualifier(); 00085 00086 Classifier *participant(); 00087 void setParticipant(Classifier *value); 00088 void clearParticipant(); 00089 00090 const OMF::Set &specification(); 00091 void addSpecification(Classifier *value); 00092 void removeSpecification(Classifier *value); 00093 void clearSpecification(); 00094 00095 private: 00096 OMF::Boolean _isNavigable; 00097 OrderingKind _ordering; 00098 AggregationKind _aggregation; 00099 ScopeKind _targetScope; 00100 Multiplicity *_multiplicity; 00101 ChangeableKind _changeability; 00102 Association *_association; 00103 OMF::Set _qualifier; 00104 Classifier *_participant; 00105 OMF::Set _specification; 00106 }; 00107 00108 00109 struct AssociationEndImpl : virtual public UML::AssociationEnd 00110 { 00111 AssociationEndImpl() : 00112 OMF::ModelObject( 00113 "UML.AssociationEnd", 00114 &AssociationEnd::Proxy::instance(), 00115 &UMLPackage::instance()), 00116 Element(), 00117 ModelElement(), 00118 AssociationEnd() 00119 {} 00120 00121 virtual ~AssociationEndImpl() 00122 {} 00123 }; 00124 } 00125 00126 #endif