Eclipse SUMO - Simulation of Urban MObility
Loading...
Searching...
No Matches
GNEViewNetHelper::InspectedElements Class Reference

class used for group inspected elements More...

#include <GNEViewNetHelper.h>

Collaboration diagram for GNEViewNetHelper::InspectedElements:
[legend]

Public Member Functions

 InspectedElements ()
 constructor
inspect functions

inspect AC

void inspectAC (GNEAttributeCarrier *AC)
void inspectACs (const std::vector< GNEAttributeCarrier * > &ACs)
 inspect multiple ACs
void uninspectAC (GNEAttributeCarrier *AC)
 uninspect AC
void clearInspectedElements ()
 clear inspected AC
get functions

get first inspected AC (needed because the main container is a hash)

GNEAttributeCarriergetFirstAC () const
const std::unordered_set< GNEAttributeCarrier * > & getACs () const
 get hash table with all inspected ACs
check functions
bool isACInspected (GNEAttributeCarrier *AC) const
bool isACInspected (const GNEAttributeCarrier *AC) const
bool isInspectingElements () const
 check if we're inspecting at least one element
bool isInspectingSingleElement () const
 check if we're inspecting exactly one element
bool isInspectingMultipleElements () const
 check if we're inspecting more than one elements

Private Member Functions

 InspectedElements (const InspectedElements &)=delete
 Invalidated copy constructor.
InspectedElementsoperator= (const InspectedElements &)=delete
 Invalidated assignment operator.

Private Attributes

GNEAttributeCarriermyFirstInspectedAC = nullptr
 first inspected element (usually the clicked element)
std::unordered_set< GNEAttributeCarrier * > myInspectedACs
 hash table with all inspected ACs (we use a set to make deletion of massive elements more quickly)

Detailed Description

class used for group inspected elements

Definition at line 239 of file GNEViewNetHelper.h.

Constructor & Destructor Documentation

◆ InspectedElements() [1/2]

GNEViewNetHelper::InspectedElements::InspectedElements ( )

constructor

Definition at line 223 of file GNEViewNetHelper.cpp.

Referenced by InspectedElements(), and operator=().

Here is the caller graph for this function:

◆ InspectedElements() [2/2]

GNEViewNetHelper::InspectedElements::InspectedElements ( const InspectedElements & )
privatedelete

Invalidated copy constructor.

References InspectedElements().

Member Function Documentation

◆ clearInspectedElements()

void GNEViewNetHelper::InspectedElements::clearInspectedElements ( )

clear inspected AC

Definition at line 268 of file GNEViewNetHelper.cpp.

References myFirstInspectedAC, and myInspectedACs.

◆ getACs()

const std::unordered_set< GNEAttributeCarrier * > & GNEViewNetHelper::InspectedElements::getACs ( ) const

get hash table with all inspected ACs

Definition at line 281 of file GNEViewNetHelper.cpp.

References myInspectedACs.

◆ getFirstAC()

GNEAttributeCarrier * GNEViewNetHelper::InspectedElements::getFirstAC ( ) const

Definition at line 275 of file GNEViewNetHelper.cpp.

References myFirstInspectedAC.

◆ inspectAC()

void GNEViewNetHelper::InspectedElements::inspectAC ( GNEAttributeCarrier * AC)

Definition at line 227 of file GNEViewNetHelper.cpp.

References myFirstInspectedAC, and myInspectedACs.

◆ inspectACs()

void GNEViewNetHelper::InspectedElements::inspectACs ( const std::vector< GNEAttributeCarrier * > & ACs)

inspect multiple ACs

Definition at line 239 of file GNEViewNetHelper.cpp.

References myFirstInspectedAC, and myInspectedACs.

◆ isACInspected() [1/2]

bool GNEViewNetHelper::InspectedElements::isACInspected ( const GNEAttributeCarrier * AC) const

Definition at line 299 of file GNEViewNetHelper.cpp.

References myFirstInspectedAC, and myInspectedACs.

◆ isACInspected() [2/2]

◆ isInspectingElements()

bool GNEViewNetHelper::InspectedElements::isInspectingElements ( ) const

check if we're inspecting at least one element

Definition at line 312 of file GNEViewNetHelper.cpp.

References myInspectedACs.

◆ isInspectingMultipleElements()

bool GNEViewNetHelper::InspectedElements::isInspectingMultipleElements ( ) const

check if we're inspecting more than one elements

Definition at line 324 of file GNEViewNetHelper.cpp.

References myInspectedACs.

◆ isInspectingSingleElement()

bool GNEViewNetHelper::InspectedElements::isInspectingSingleElement ( ) const

check if we're inspecting exactly one element

Definition at line 318 of file GNEViewNetHelper.cpp.

References myInspectedACs.

◆ operator=()

InspectedElements & GNEViewNetHelper::InspectedElements::operator= ( const InspectedElements & )
privatedelete

Invalidated assignment operator.

References InspectedElements().

◆ uninspectAC()

void GNEViewNetHelper::InspectedElements::uninspectAC ( GNEAttributeCarrier * AC)

uninspect AC

Definition at line 253 of file GNEViewNetHelper.cpp.

References myFirstInspectedAC, and myInspectedACs.

Field Documentation

◆ myFirstInspectedAC

GNEAttributeCarrier* GNEViewNetHelper::InspectedElements::myFirstInspectedAC = nullptr
private

first inspected element (usually the clicked element)

Definition at line 292 of file GNEViewNetHelper.h.

Referenced by clearInspectedElements(), getFirstAC(), inspectAC(), inspectACs(), isACInspected(), isACInspected(), and uninspectAC().

◆ myInspectedACs

std::unordered_set<GNEAttributeCarrier*> GNEViewNetHelper::InspectedElements::myInspectedACs
private

hash table with all inspected ACs (we use a set to make deletion of massive elements more quickly)

Definition at line 295 of file GNEViewNetHelper.h.

Referenced by clearInspectedElements(), getACs(), inspectAC(), inspectACs(), isACInspected(), isACInspected(), isInspectingElements(), isInspectingMultipleElements(), isInspectingSingleElement(), and uninspectAC().


The documentation for this class was generated from the following files: