37 CGraph::CGraph(const ::std::string& OID, const ::std::string& Type, const ::std::string& ID,
const std::map< ::std::string, ::GOPPRR::CProperty* >& Properties,
const std::vector< ::GOPPRR::CBinding >& BindingSet,
const std::vector< ::GOPPRR::CGraphicalContainer >& Containers,
const std::map< std::string, ::GOPPRR::CObject* >& ObjectSet,
const std::map< std::string, ::GOPPRR::CPort* >& PortSet,
const std::map< std::string, ::GOPPRR::CRelationship* >& RelationshipSet,
const std::map< std::string, ::GOPPRR::CRole* >& RoleSet)
throw()
39 m_BindingSet(BindingSet),
40 m_ObjectSet(ObjectSet),
42 m_RelationshipSet(RelationshipSet),
44 m_Containers(Containers)
56 m_BindingSet(Source.m_BindingSet),
57 m_ObjectSet(Source.m_ObjectSet),
58 m_PortSet(Source.m_PortSet),
59 m_RelationshipSet(Source.m_RelationshipSet),
60 m_RoleSet(Source.m_RoleSet),
61 m_Containers(Source.m_Containers)
84 bool bFoundInCalls(
false);
85 ::std::map< ::std::string, ::GOPPRR::CRole* > Roles;
92 for (x = 0; x != m_BindingSet.size(); x++)
95 for (y = 0; y < m_BindingSet[x].m_Connection.m_Calls.size() && !bFoundInCalls; y++)
98 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pObject == pObject)
101 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pRole != 0)
104 Roles[m_BindingSet[x].m_Connection.m_Calls[y].m_pRole->m_OID] = m_BindingSet[x].m_Connection.m_Calls[y].m_pRole;
107 bFoundInCalls =
true;
116 bFoundInCalls =
false;
122 if (bUseException && Roles.empty())
141 bool bFoundInCalls(
false);
142 ::std::map< ::std::string, ::GOPPRR::CRole* > Roles;
149 for (x = 0; x != m_BindingSet.size(); x++)
152 for (y = 0; y < m_BindingSet[x].m_Connection.m_Calls.size() && !bFoundInCalls; y++)
155 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pObject == pObject)
158 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pRole != 0)
161 if ((!bSubString && m_BindingSet[x].m_Connection.m_Calls[y].m_pRole->m_Type == Type ) ||
162 (bSubString && m_BindingSet[x].m_Connection.m_Calls[y].m_pRole->m_Type.find(Type) != ::std::string::npos))
165 Roles[m_BindingSet[x].m_Connection.m_Calls[y].m_pRole->m_OID] = m_BindingSet[x].m_Connection.m_Calls[y].m_pRole;
168 bFoundInCalls =
true;
179 bFoundInCalls =
false;
185 if (bUseException && Roles.empty())
204 bool bFoundInCalls(
false);
205 ::std::map< ::std::string, ::GOPPRR::CRole* > Roles;
212 for (x = 0; x != m_BindingSet.size(); x++)
215 for (y = 0; y < m_BindingSet[x].m_Connection.m_Calls.size() && !bFoundInCalls; y++)
218 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pPort == pPort && m_BindingSet[x].m_Connection.m_Calls[y].m_pObject == pObject)
221 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pRole != 0)
224 Roles[m_BindingSet[x].m_Connection.m_Calls[y].m_pRole->m_OID] = m_BindingSet[x].m_Connection.m_Calls[y].m_pRole;
227 bFoundInCalls =
true;
236 bFoundInCalls =
false;
241 if (bUseException && Roles.empty())
261 ::std::map< ::std::string, ::GOPPRR::CRole* > Roles;
268 for (x = 0; x != m_BindingSet.size(); x++)
271 if (m_BindingSet[x].m_pRelationship == pRelationship)
274 for (y = 0; y < m_BindingSet[x].m_Connection.m_Calls.size(); y++)
277 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pRole != 0)
280 Roles[m_BindingSet[x].m_Connection.m_Calls[y].m_pRole->m_OID] = m_BindingSet[x].m_Connection.m_Calls[y].m_pRole;
292 if (bUseException && Roles.empty())
311 bool bFoundInCalls(
false);
312 ::std::map< ::std::string, ::GOPPRR::CRole* > Roles;
319 for (x = 0; x != m_BindingSet.size(); x++)
322 for (y = 0; y < m_BindingSet[x].m_Connection.m_Calls.size() && !bFoundInCalls; y++)
325 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pPort == pPort && m_BindingSet[x].m_Connection.m_Calls[y].m_pObject == pObject)
328 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pRole != 0)
331 if ((!bSubString && m_BindingSet[x].m_Connection.m_Calls[y].m_pRole->m_Type == Type ) ||
332 (bSubString && m_BindingSet[x].m_Connection.m_Calls[y].m_pRole->m_Type.find(Type) != ::std::string::npos))
335 Roles[m_BindingSet[x].m_Connection.m_Calls[y].m_pRole->m_OID] = m_BindingSet[x].m_Connection.m_Calls[y].m_pRole;
338 bFoundInCalls =
true;
349 bFoundInCalls =
false;
355 if (bUseException && Roles.empty())
374 ::std::map< ::std::string, ::GOPPRR::CRole* > Roles;
381 for (x = 0; x != m_BindingSet.size(); x++)
384 if (m_BindingSet[x].m_pRelationship == pRelationship)
387 for (y = 0; y < m_BindingSet[x].m_Connection.m_Calls.size(); y++)
390 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pRole != 0)
393 if ((!bSubString && m_BindingSet[x].m_Connection.m_Calls[y].m_pRole->m_Type == Type ) ||
394 (bSubString && m_BindingSet[x].m_Connection.m_Calls[y].m_pRole->m_Type.find(Type) != ::std::string::npos))
397 Roles[m_BindingSet[x].m_Connection.m_Calls[y].m_pRole->m_OID] = m_BindingSet[x].m_Connection.m_Calls[y].m_pRole;
411 if (bUseException && Roles.empty())
430 ::std::map< ::std::string, ::GOPPRR::CRole* > Roles;
438 for (x = 0; x < m_BindingSet.size(); x++)
441 for (y = 0; y < m_BindingSet[x].m_Connection.m_Calls.size(); y++)
444 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pRole == pRole)
447 for (z = 0; z < m_BindingSet[x].m_Connection.m_Calls.size(); z++)
450 if (((!bSubString && m_BindingSet[x].m_Connection.m_Calls[z].m_pRole->m_Type == Type ) ||
451 (bSubString && m_BindingSet[x].m_Connection.m_Calls[z].m_pRole->m_Type.find(Type) != ::std::string::npos)) &&
452 m_BindingSet[x].m_Connection.m_Calls[z].m_pRole != pRole)
455 Roles[m_BindingSet[x].m_Connection.m_Calls[z].m_pRole->m_OID] = m_BindingSet[x].m_Connection.m_Calls[z].m_pRole;
469 if (bUseException && Roles.empty())
488 bool bFoundInCalls(
false);
489 ::std::map< ::std::string, ::GOPPRR::CRelationship* > Relationships;
496 for (x = 0; x != m_BindingSet.size(); x++)
499 for (y = 0; y < m_BindingSet[x].m_Connection.m_Calls.size() && !bFoundInCalls; y++)
502 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pRole == pRole)
505 if (m_BindingSet[x].m_pRelationship != 0)
508 Relationships[m_BindingSet[x].m_pRelationship->m_OID] = m_BindingSet[x].m_pRelationship;
511 bFoundInCalls =
true;
520 bFoundInCalls =
false;
526 if (bUseException && Relationships.empty())
534 return (Relationships);
545 bool bFoundInCalls(
false);
546 ::std::map< ::std::string, ::GOPPRR::CRelationship* > Relationships;
553 for (x = 0; x != m_BindingSet.size(); x++)
556 for (y = 0; y < m_BindingSet[x].m_Connection.m_Calls.size() && !bFoundInCalls; y++)
559 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pRole == pRole)
562 if (m_BindingSet[x].m_pRelationship != 0)
565 if ((!bSubString && m_BindingSet[x].m_pRelationship->m_Type == Type ) ||
566 (bSubString && m_BindingSet[x].m_pRelationship->m_Type.find(Type) != ::std::string::npos))
569 Relationships[m_BindingSet[x].m_pRelationship->m_OID] = m_BindingSet[x].m_pRelationship;
572 bFoundInCalls =
true;
583 bFoundInCalls =
false;
589 if (bUseException && Relationships.empty())
598 return (Relationships);
609 bool bFoundInCalls(
false);
610 ::std::map< ::std::string, ::GOPPRR::CPort* > Ports;
617 for (x = 0; x != m_BindingSet.size(); x++)
620 for (y = 0; y < m_BindingSet[x].m_Connection.m_Calls.size() && !bFoundInCalls; y++)
623 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pRole == pRole)
626 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pPort != 0)
629 Ports[m_BindingSet[x].m_Connection.m_Calls[y].m_pPort->m_OID] = m_BindingSet[x].m_Connection.m_Calls[y].m_pPort;
632 bFoundInCalls =
true;
641 bFoundInCalls =
false;
647 if (bUseException && Ports.empty())
666 bool bFoundInCalls(
false);
667 ::std::map< ::std::string, ::GOPPRR::CPort* > Ports;
674 for (x = 0; x != m_BindingSet.size(); x++)
677 for (y = 0; y < m_BindingSet[x].m_Connection.m_Calls.size() && !bFoundInCalls; y++)
680 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pObject == pObject)
683 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pPort != 0)
686 Ports[m_BindingSet[x].m_Connection.m_Calls[y].m_pPort->m_OID] = m_BindingSet[x].m_Connection.m_Calls[y].m_pPort;
689 bFoundInCalls =
true;
698 bFoundInCalls =
false;
704 if (bUseException && Ports.empty())
723 ::std::map< ::std::string, ::GOPPRR::CPort* > Ports;
730 for (x = 0; x != m_BindingSet.size(); x++)
733 for (y = 0; y < m_BindingSet[x].m_Connection.m_Calls.size(); y++)
736 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pObject == pObject)
739 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pPort != 0)
742 if ((!bSubString && m_BindingSet[x].m_Connection.m_Calls[y].m_pPort->m_Type == Type ) ||
743 (bSubString && m_BindingSet[x].m_Connection.m_Calls[y].m_pPort->m_Type.find(Type) != ::std::string::npos))
746 Ports[m_BindingSet[x].m_Connection.m_Calls[y].m_pPort->m_OID] = m_BindingSet[x].m_Connection.m_Calls[y].m_pPort;
760 if (bUseException && Ports.empty())
779 bool bFoundInCalls(
false);
780 ::std::map< ::std::string, ::GOPPRR::CObject* > Objects;
787 for (x = 0; x != m_BindingSet.size(); x++)
790 for (y = 0; y < m_BindingSet[x].m_Connection.m_Calls.size() && !bFoundInCalls; y++)
793 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pPort == pPort && m_BindingSet[x].m_Connection.m_Calls[y].m_pRole == pRole)
796 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pObject != 0)
799 Objects[m_BindingSet[x].m_Connection.m_Calls[y].m_pObject->m_OID] = m_BindingSet[x].m_Connection.m_Calls[y].m_pObject;
802 bFoundInCalls =
true;
811 bFoundInCalls =
false;
817 if (bUseException && Objects.empty())
836 bool bFoundInCalls(
false);
837 ::std::map< ::std::string, ::GOPPRR::CObject* > Objects;
844 for (x = 0; x != m_BindingSet.size(); x++)
847 for (y = 0; y < m_BindingSet[x].m_Connection.m_Calls.size() && !bFoundInCalls; y++)
850 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pRole == pRole)
853 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pObject != 0)
856 Objects[m_BindingSet[x].m_Connection.m_Calls[y].m_pObject->m_OID] = m_BindingSet[x].m_Connection.m_Calls[y].m_pObject;
859 bFoundInCalls =
true;
868 bFoundInCalls =
false;
874 if (bUseException && Objects.empty())
893 bool bFoundInCalls(
false);
894 ::std::map< ::std::string, ::GOPPRR::CObject* > Objects;
901 for (x = 0; x != m_BindingSet.size(); x++)
904 for (y = 0; y < m_BindingSet[x].m_Connection.m_Calls.size() && !bFoundInCalls; y++)
907 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pRole == pRole)
910 if (m_BindingSet[x].m_Connection.m_Calls[y].m_pObject != 0)
913 if ((!bSubString && m_BindingSet[x].m_Connection.m_Calls[y].m_pObject->m_Type == Type ) ||
914 (bSubString && m_BindingSet[x].m_Connection.m_Calls[y].m_pObject->m_Type.find(Type) != ::std::string::npos))
917 Objects[m_BindingSet[x].m_Connection.m_Calls[y].m_pObject->m_OID] = m_BindingSet[x].m_Connection.m_Calls[y].m_pObject;
920 bFoundInCalls =
true;
931 bFoundInCalls =
false;
937 if (bUseException && Objects.empty())
956 ::std::map< ::std::string, ::GOPPRR::CObject* > Objects;
962 for (Object = this->m_ObjectSet.begin(); Object != this->m_ObjectSet.end(); Object++)
965 if ((!bSubString && Object->second->m_Type == Type ) || (bSubString && Object->second->m_Type.find(Type) != ::std::string::npos))
968 Objects[ Object->second->m_OID ] = Object->second;
976 if (bUseException && Objects.empty())
995 bool bFoundInContainer(
false);
996 ::std::map< ::std::string, ::GOPPRR::CObject* > Objects;
998 ::std::map< ::std::string, ::GOPPRR::CObject* >::const_iterator y(0);
1003 for (x = 0; x < m_Containers.size(); x++)
1006 if (m_Containers[x].m_pContainer == pObject)
1009 for (y = m_Containers[x].m_ContainedObjects.begin(); y != m_Containers[x].m_ContainedObjects.end() && !bFoundInContainer; y++)
1012 if (y->second == pObject)
1015 Objects[y->second->m_OID] = y->second;
1018 bFoundInContainer =
true;
1025 bFoundInContainer =
false;
1033 if (bUseException && Objects.empty())
1052 ::std::map< ::std::string, ::GOPPRR::CObject* > Objects;
1058 for (x = 0; x < m_Containers.size(); x++)
1061 if (m_Containers[x].m_pContainer == pObject)
1064 Objects.insert(m_Containers[x].m_ContainedObjects.begin(), m_Containers[x].m_ContainedObjects.end());
1072 if (bUseException && Objects.empty())
1093 m_ObjectSet = Source.m_ObjectSet;
1094 m_PortSet = Source.m_PortSet;
1095 m_RelationshipSet = Source.m_RelationshipSet;
1096 m_RoleSet = Source.m_RoleSet;
1097 m_Containers = Source.m_Containers;
1100 ::GOPPRR::CNonProperty::operator =(Source);