![]() |
Eclipse SUMO - Simulation of Urban MObility
|
Hierarchical container (used for keep myParent and myChildren. More...
#include <GNEHierarchicalContainer.h>
Public Member Functions | |
template<> | |
void | addChildElement (GNEAdditional *additional) |
template<> | |
void | addChildElement (GNEDemandElement *demandElement) |
template<> | |
void | addChildElement (GNEEdge *edge) |
template<> | |
void | addChildElement (GNEGenericData *genericData) |
template<> | |
void | addChildElement (GNEJunction *junction) |
template<> | |
void | addChildElement (GNELane *lane) |
template<typename T > | |
void | addChildElement (T *element) |
add child element | |
template<> | |
void | addParentElement (GNEAdditional *additional) |
template<> | |
void | addParentElement (GNEDemandElement *demandElement) |
template<> | |
void | addParentElement (GNEEdge *edge) |
template<> | |
void | addParentElement (GNEGenericData *genericData) |
template<> | |
void | addParentElement (GNEJunction *junction) |
template<> | |
void | addParentElement (GNELane *lane) |
template<typename T > | |
void | addParentElement (T *element) |
add parent element | |
template<> | |
const std::vector< GNEJunction * > & | getChildren () const |
template<> | |
const std::vector< GNEEdge * > & | getChildren () const |
template<> | |
const std::vector< GNELane * > & | getChildren () const |
template<> | |
const std::vector< GNEAdditional * > & | getChildren () const |
template<> | |
const std::vector< GNEDemandElement * > & | getChildren () const |
template<> | |
const std::vector< GNEGenericData * > & | getChildren () const |
template<typename T > | |
const T & | getChildren () const |
get children | |
size_t | getContainerSize () const |
get container size | |
template<> | |
const std::vector< GNEJunction * > & | getParents () const |
template<> | |
const std::vector< GNEEdge * > & | getParents () const |
template<> | |
const std::vector< GNELane * > & | getParents () const |
template<> | |
const std::vector< GNEAdditional * > & | getParents () const |
template<> | |
const std::vector< GNEDemandElement * > & | getParents () const |
template<> | |
const std::vector< GNEGenericData * > & | getParents () const |
template<typename T > | |
const T & | getParents () const |
get parents | |
GNEHierarchicalContainer () | |
default constructor | |
GNEHierarchicalContainer (const std::vector< GNEJunction * > &parentJunctions, const std::vector< GNEEdge * > &parentEdges, const std::vector< GNELane * > &parentLanes, const std::vector< GNEAdditional * > &parentAdditionals, const std::vector< GNEDemandElement * > &ParentDemandElements, const std::vector< GNEGenericData * > &parentGenericDatas) | |
parameter constructor (only for parents) | |
template<> | |
void | removeChildElement (GNEAdditional *additional) |
template<> | |
void | removeChildElement (GNEDemandElement *demandElement) |
template<> | |
void | removeChildElement (GNEEdge *edge) |
template<> | |
void | removeChildElement (GNEGenericData *genericData) |
template<> | |
void | removeChildElement (GNEJunction *junction) |
template<> | |
void | removeChildElement (GNELane *lane) |
template<typename T > | |
void | removeChildElement (T *element) |
remove child element | |
template<> | |
void | removeParentElement (GNEAdditional *additional) |
template<> | |
void | removeParentElement (GNEDemandElement *demandElement) |
template<> | |
void | removeParentElement (GNEEdge *edge) |
template<> | |
void | removeParentElement (GNEGenericData *genericData) |
template<> | |
void | removeParentElement (GNEJunction *junction) |
template<> | |
void | removeParentElement (GNELane *lane) |
template<typename T > | |
void | removeParentElement (T *element) |
remove parent element | |
template<> | |
void | setChildren (const std::vector< GNEAdditional * > &newChildren) |
template<> | |
void | setChildren (const std::vector< GNEDemandElement * > &newChildren) |
template<> | |
void | setChildren (const std::vector< GNEEdge * > &newChildren) |
template<> | |
void | setChildren (const std::vector< GNEGenericData * > &newChildren) |
template<> | |
void | setChildren (const std::vector< GNEJunction * > &newChildren) |
template<> | |
void | setChildren (const std::vector< GNELane * > &newChildren) |
template<typename T > | |
void | setChildren (const T &newChildren) |
set children | |
template<> | |
void | setParents (const std::vector< GNEAdditional * > &newParents) |
template<> | |
void | setParents (const std::vector< GNEDemandElement * > &newParents) |
template<> | |
void | setParents (const std::vector< GNEEdge * > &newParents) |
template<> | |
void | setParents (const std::vector< GNEGenericData * > &newParents) |
template<> | |
void | setParents (const std::vector< GNEJunction * > &newParents) |
template<> | |
void | setParents (const std::vector< GNELane * > &newParents) |
template<typename T > | |
void | setParents (const T &newParents) |
set parents | |
Private Attributes | |
std::vector< GNEAdditional * > | myChildAdditionals |
vector with the child additional | |
std::vector< GNEDemandElement * > | myChildDemandElements |
vector with the child demand elements | |
std::vector< GNEEdge * > | myChildEdges |
vector with the child edges | |
std::vector< GNEGenericData * > | myChildGenericDatas |
vector with the generic child data elements | |
std::vector< GNEJunction * > | myChildJunctions |
vector with the child junctions | |
std::vector< GNELane * > | myChildLanes |
vector with the child lanes | |
std::vector< GNEAdditional * > | myParentAdditionals |
vector of parent additionals | |
std::vector< GNEDemandElement * > | myParentDemandElements |
vector of parent demand elements | |
std::vector< GNEEdge * > | myParentEdges |
vector of parent edges | |
std::vector< GNEGenericData * > | myParentGenericDatas |
vector of parent generic datas | |
std::vector< GNEJunction * > | myParentJunctions |
vector of parent junctions | |
std::vector< GNELane * > | myParentLanes |
vector of parent lanes | |
Hierarchical container (used for keep myParent and myChildren.
Definition at line 42 of file GNEHierarchicalContainer.h.
GNEHierarchicalContainer::GNEHierarchicalContainer | ( | ) |
default constructor
Definition at line 30 of file GNEHierarchicalContainer.cpp.
GNEHierarchicalContainer::GNEHierarchicalContainer | ( | const std::vector< GNEJunction * > & | parentJunctions, |
const std::vector< GNEEdge * > & | parentEdges, | ||
const std::vector< GNELane * > & | parentLanes, | ||
const std::vector< GNEAdditional * > & | parentAdditionals, | ||
const std::vector< GNEDemandElement * > & | ParentDemandElements, | ||
const std::vector< GNEGenericData * > & | parentGenericDatas | ||
) |
parameter constructor (only for parents)
Definition at line 33 of file GNEHierarchicalContainer.cpp.
void GNEHierarchicalContainer::addChildElement | ( | GNEAdditional * | additional | ) |
Definition at line 195 of file GNEHierarchicalContainer.cpp.
References myChildAdditionals.
void GNEHierarchicalContainer::addChildElement | ( | GNEDemandElement * | demandElement | ) |
Definition at line 201 of file GNEHierarchicalContainer.cpp.
References myChildDemandElements.
void GNEHierarchicalContainer::addChildElement | ( | GNEEdge * | edge | ) |
Definition at line 183 of file GNEHierarchicalContainer.cpp.
References myChildEdges.
void GNEHierarchicalContainer::addChildElement | ( | GNEGenericData * | genericData | ) |
Definition at line 208 of file GNEHierarchicalContainer.cpp.
References myChildGenericDatas.
void GNEHierarchicalContainer::addChildElement | ( | GNEJunction * | junction | ) |
Definition at line 177 of file GNEHierarchicalContainer.cpp.
References myChildJunctions.
void GNEHierarchicalContainer::addChildElement | ( | GNELane * | lane | ) |
Definition at line 189 of file GNEHierarchicalContainer.cpp.
References myChildLanes.
void GNEHierarchicalContainer::addChildElement | ( | T * | element | ) |
add child element
Referenced by GNEHierarchicalElement::addChildElement().
void GNEHierarchicalContainer::addParentElement | ( | GNEAdditional * | additional | ) |
Definition at line 87 of file GNEHierarchicalContainer.cpp.
References myParentAdditionals.
void GNEHierarchicalContainer::addParentElement | ( | GNEDemandElement * | demandElement | ) |
Definition at line 93 of file GNEHierarchicalContainer.cpp.
References myParentDemandElements.
void GNEHierarchicalContainer::addParentElement | ( | GNEEdge * | edge | ) |
Definition at line 75 of file GNEHierarchicalContainer.cpp.
References myParentEdges.
void GNEHierarchicalContainer::addParentElement | ( | GNEGenericData * | genericData | ) |
Definition at line 99 of file GNEHierarchicalContainer.cpp.
References myParentGenericDatas.
void GNEHierarchicalContainer::addParentElement | ( | GNEJunction * | junction | ) |
Definition at line 69 of file GNEHierarchicalContainer.cpp.
References myParentJunctions.
void GNEHierarchicalContainer::addParentElement | ( | GNELane * | lane | ) |
Definition at line 81 of file GNEHierarchicalContainer.cpp.
References myParentLanes.
void GNEHierarchicalContainer::addParentElement | ( | T * | element | ) |
add parent element
Referenced by GNEHierarchicalElement::addParentElement().
const std::vector< GNEJunction * > & GNEHierarchicalContainer::getChildren | ( | ) | const |
Definition at line 358 of file GNEHierarchicalContainer.cpp.
References myChildJunctions.
const std::vector< GNEEdge * > & GNEHierarchicalContainer::getChildren | ( | ) | const |
Definition at line 364 of file GNEHierarchicalContainer.cpp.
References myChildEdges.
const std::vector< GNELane * > & GNEHierarchicalContainer::getChildren | ( | ) | const |
Definition at line 370 of file GNEHierarchicalContainer.cpp.
References myChildLanes.
const std::vector< GNEAdditional * > & GNEHierarchicalContainer::getChildren | ( | ) | const |
Definition at line 376 of file GNEHierarchicalContainer.cpp.
References myChildAdditionals.
const std::vector< GNEDemandElement * > & GNEHierarchicalContainer::getChildren | ( | ) | const |
Definition at line 382 of file GNEHierarchicalContainer.cpp.
References myChildDemandElements.
const std::vector< GNEGenericData * > & GNEHierarchicalContainer::getChildren | ( | ) | const |
Definition at line 388 of file GNEHierarchicalContainer.cpp.
References myChildGenericDatas.
const T & GNEHierarchicalContainer::getChildren | ( | ) | const |
get children
Referenced by GNEChange::addElementInParentsAndChildren(), GNEHierarchicalElement::getChildAdditionals(), GNEHierarchicalElement::getChildDemandElements(), GNEHierarchicalElement::getChildEdges(), GNEHierarchicalElement::getChildGenericDatas(), GNEHierarchicalElement::getChildJunctions(), GNEHierarchicalElement::getChildLanes(), GNEChange::removeElementFromParentsAndChildren(), and GNEHierarchicalElement::replaceChildElements().
size_t GNEHierarchicalContainer::getContainerSize | ( | ) | const |
get container size
Definition at line 50 of file GNEHierarchicalContainer.cpp.
References myChildAdditionals, myChildDemandElements, myChildEdges, myChildGenericDatas, myChildJunctions, myChildLanes, myParentAdditionals, myParentDemandElements, myParentEdges, myParentGenericDatas, myParentJunctions, and myParentLanes.
Referenced by GNEHierarchicalElement::getAllHierarchicalElements().
const std::vector< GNEJunction * > & GNEHierarchicalContainer::getParents | ( | ) | const |
Definition at line 286 of file GNEHierarchicalContainer.cpp.
References myParentJunctions.
const std::vector< GNEEdge * > & GNEHierarchicalContainer::getParents | ( | ) | const |
Definition at line 292 of file GNEHierarchicalContainer.cpp.
References myParentEdges.
const std::vector< GNELane * > & GNEHierarchicalContainer::getParents | ( | ) | const |
Definition at line 298 of file GNEHierarchicalContainer.cpp.
References myParentLanes.
const std::vector< GNEAdditional * > & GNEHierarchicalContainer::getParents | ( | ) | const |
Definition at line 304 of file GNEHierarchicalContainer.cpp.
References myParentAdditionals.
const std::vector< GNEDemandElement * > & GNEHierarchicalContainer::getParents | ( | ) | const |
Definition at line 310 of file GNEHierarchicalContainer.cpp.
References myParentDemandElements.
const std::vector< GNEGenericData * > & GNEHierarchicalContainer::getParents | ( | ) | const |
Definition at line 316 of file GNEHierarchicalContainer.cpp.
References myParentGenericDatas.
const T & GNEHierarchicalContainer::getParents | ( | ) | const |
get parents
Referenced by GNEChange::addElementInParentsAndChildren(), GNEHierarchicalElement::getParentAdditionals(), GNEHierarchicalElement::getParentDemandElements(), GNEHierarchicalElement::getParentEdges(), GNEHierarchicalElement::getParentGenericDatas(), GNEHierarchicalElement::getParentJunctions(), GNEHierarchicalElement::getParentLanes(), GNEChange_DemandElement::redo(), GNEChange::removeElementFromParentsAndChildren(), GNEHierarchicalElement::replaceParentElements(), and GNEChange_DemandElement::undo().
void GNEHierarchicalContainer::removeChildElement | ( | GNEAdditional * | additional | ) |
Definition at line 250 of file GNEHierarchicalContainer.cpp.
References GNEAttributeCarrier::getTagStr(), and myChildAdditionals.
void GNEHierarchicalContainer::removeChildElement | ( | GNEDemandElement * | demandElement | ) |
Definition at line 262 of file GNEHierarchicalContainer.cpp.
References GNEAttributeCarrier::getTagStr(), and myChildDemandElements.
void GNEHierarchicalContainer::removeChildElement | ( | GNEEdge * | edge | ) |
Definition at line 226 of file GNEHierarchicalContainer.cpp.
References GNEAttributeCarrier::getTagStr(), and myChildEdges.
void GNEHierarchicalContainer::removeChildElement | ( | GNEGenericData * | genericData | ) |
Definition at line 274 of file GNEHierarchicalContainer.cpp.
References GNEAttributeCarrier::getTagStr(), and myChildGenericDatas.
void GNEHierarchicalContainer::removeChildElement | ( | GNEJunction * | junction | ) |
Definition at line 214 of file GNEHierarchicalContainer.cpp.
References GNEAttributeCarrier::getTagStr(), and myChildJunctions.
void GNEHierarchicalContainer::removeChildElement | ( | GNELane * | lane | ) |
Definition at line 238 of file GNEHierarchicalContainer.cpp.
References GNEAttributeCarrier::getTagStr(), and myChildLanes.
void GNEHierarchicalContainer::removeChildElement | ( | T * | element | ) |
remove child element
Referenced by GNEHierarchicalElement::removeChildElement().
void GNEHierarchicalContainer::removeParentElement | ( | GNEAdditional * | additional | ) |
Definition at line 141 of file GNEHierarchicalContainer.cpp.
References GNEAttributeCarrier::getID(), GNEAttributeCarrier::getTagStr(), and myParentAdditionals.
void GNEHierarchicalContainer::removeParentElement | ( | GNEDemandElement * | demandElement | ) |
Definition at line 153 of file GNEHierarchicalContainer.cpp.
References GNEAttributeCarrier::getTagStr(), and myParentDemandElements.
void GNEHierarchicalContainer::removeParentElement | ( | GNEEdge * | edge | ) |
Definition at line 117 of file GNEHierarchicalContainer.cpp.
References GNEAttributeCarrier::getID(), GNEAttributeCarrier::getTagStr(), and myParentEdges.
void GNEHierarchicalContainer::removeParentElement | ( | GNEGenericData * | genericData | ) |
Definition at line 165 of file GNEHierarchicalContainer.cpp.
References GNEAttributeCarrier::getTagStr(), and myParentGenericDatas.
void GNEHierarchicalContainer::removeParentElement | ( | GNEJunction * | junction | ) |
Definition at line 105 of file GNEHierarchicalContainer.cpp.
References GNEAttributeCarrier::getID(), GNEAttributeCarrier::getTagStr(), and myParentJunctions.
void GNEHierarchicalContainer::removeParentElement | ( | GNELane * | lane | ) |
Definition at line 129 of file GNEHierarchicalContainer.cpp.
References GNEAttributeCarrier::getID(), GNEAttributeCarrier::getTagStr(), and myParentLanes.
void GNEHierarchicalContainer::removeParentElement | ( | T * | element | ) |
remove parent element
Referenced by GNEHierarchicalElement::removeParentElement().
void GNEHierarchicalContainer::setChildren | ( | const std::vector< GNEAdditional * > & | newChildren | ) |
Definition at line 412 of file GNEHierarchicalContainer.cpp.
References myChildAdditionals.
void GNEHierarchicalContainer::setChildren | ( | const std::vector< GNEDemandElement * > & | newChildren | ) |
Definition at line 418 of file GNEHierarchicalContainer.cpp.
References myChildDemandElements.
void GNEHierarchicalContainer::setChildren | ( | const std::vector< GNEEdge * > & | newChildren | ) |
Definition at line 400 of file GNEHierarchicalContainer.cpp.
References myChildEdges.
void GNEHierarchicalContainer::setChildren | ( | const std::vector< GNEGenericData * > & | newChildren | ) |
Definition at line 424 of file GNEHierarchicalContainer.cpp.
References myChildGenericDatas.
void GNEHierarchicalContainer::setChildren | ( | const std::vector< GNEJunction * > & | newChildren | ) |
Definition at line 394 of file GNEHierarchicalContainer.cpp.
References myChildJunctions.
void GNEHierarchicalContainer::setChildren | ( | const std::vector< GNELane * > & | newChildren | ) |
Definition at line 406 of file GNEHierarchicalContainer.cpp.
References myChildLanes.
void GNEHierarchicalContainer::setChildren | ( | const T & | newChildren | ) |
set children
Referenced by GNEHierarchicalElement::replaceChildElements().
void GNEHierarchicalContainer::setParents | ( | const std::vector< GNEAdditional * > & | newParents | ) |
Definition at line 340 of file GNEHierarchicalContainer.cpp.
References myParentAdditionals.
void GNEHierarchicalContainer::setParents | ( | const std::vector< GNEDemandElement * > & | newParents | ) |
Definition at line 346 of file GNEHierarchicalContainer.cpp.
References myParentDemandElements.
void GNEHierarchicalContainer::setParents | ( | const std::vector< GNEEdge * > & | newParents | ) |
Definition at line 328 of file GNEHierarchicalContainer.cpp.
References myParentEdges.
void GNEHierarchicalContainer::setParents | ( | const std::vector< GNEGenericData * > & | newParents | ) |
Definition at line 352 of file GNEHierarchicalContainer.cpp.
References myParentGenericDatas.
void GNEHierarchicalContainer::setParents | ( | const std::vector< GNEJunction * > & | newParents | ) |
Definition at line 322 of file GNEHierarchicalContainer.cpp.
References myParentJunctions.
void GNEHierarchicalContainer::setParents | ( | const std::vector< GNELane * > & | newParents | ) |
Definition at line 334 of file GNEHierarchicalContainer.cpp.
References myParentLanes.
void GNEHierarchicalContainer::setParents | ( | const T & | newParents | ) |
set parents
Referenced by GNEHierarchicalElement::replaceParentElements().
|
private |
vector with the child additional
Definition at line 121 of file GNEHierarchicalContainer.h.
Referenced by addChildElement(), getChildren(), getContainerSize(), removeChildElement(), and setChildren().
|
private |
vector with the child demand elements
Definition at line 124 of file GNEHierarchicalContainer.h.
Referenced by addChildElement(), getChildren(), getContainerSize(), removeChildElement(), and setChildren().
|
private |
vector with the child edges
Definition at line 115 of file GNEHierarchicalContainer.h.
Referenced by addChildElement(), getChildren(), getContainerSize(), removeChildElement(), and setChildren().
|
private |
vector with the generic child data elements
Definition at line 127 of file GNEHierarchicalContainer.h.
Referenced by addChildElement(), getChildren(), getContainerSize(), removeChildElement(), and setChildren().
|
private |
vector with the child junctions
Definition at line 112 of file GNEHierarchicalContainer.h.
Referenced by addChildElement(), getChildren(), getContainerSize(), removeChildElement(), and setChildren().
|
private |
vector with the child lanes
Definition at line 118 of file GNEHierarchicalContainer.h.
Referenced by addChildElement(), getChildren(), getContainerSize(), removeChildElement(), and setChildren().
|
private |
vector of parent additionals
Definition at line 103 of file GNEHierarchicalContainer.h.
Referenced by addParentElement(), getContainerSize(), getParents(), removeParentElement(), and setParents().
|
private |
vector of parent demand elements
Definition at line 106 of file GNEHierarchicalContainer.h.
Referenced by addParentElement(), getContainerSize(), getParents(), removeParentElement(), and setParents().
|
private |
vector of parent edges
Definition at line 97 of file GNEHierarchicalContainer.h.
Referenced by addParentElement(), getContainerSize(), getParents(), removeParentElement(), and setParents().
|
private |
vector of parent generic datas
Definition at line 109 of file GNEHierarchicalContainer.h.
Referenced by addParentElement(), getContainerSize(), getParents(), removeParentElement(), and setParents().
|
private |
vector of parent junctions
Definition at line 94 of file GNEHierarchicalContainer.h.
Referenced by addParentElement(), getContainerSize(), getParents(), removeParentElement(), and setParents().
|
private |
vector of parent lanes
Definition at line 100 of file GNEHierarchicalContainer.h.
Referenced by addParentElement(), getContainerSize(), getParents(), removeParentElement(), and setParents().