Sequence Chart Studio  svn HEAD revision
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Public Member Functions | Protected Member Functions | Private Attributes | List of all members
StrictOrderArea Class Reference

EventArea whose events are ordered linearly as they follow each other. More...

#include <StrictOrderArea.h>

Inheritance diagram for StrictOrderArea:
Inheritance graph
Collaboration diagram for StrictOrderArea:
Collaboration graph

Public Member Functions

 StrictOrderArea ()
 
 StrictOrderArea (StrictOrderArea *original)
 
virtual ~StrictOrderArea ()
 
const EventPtr get_first_event () const
 
const EventPtr get_last_event () const
 
const EventPtrListget_events () const
 
bool is_empty () const
 
void add_event (const EventPtr &e, Event *predecessor)
 
void remove_event (Event *e)
 Removes a given event from the area. More...
 
EventPSet get_predecessor_events (const Event *e) const
 Returns predecessor events of a given event within this area, or an empty set if this is a minimal event. More...
 
EventPSet get_successor_events (const Event *e) const
 Returns successor events of a given event within this area, or an empty set if this is a maximal event. More...
 
EventPList get_minimal_events () const
 Returns the list of minimal events in this area, i.e., those not having any predecessors within the area, in the order of their insertion to the area. More...
 
EventPList get_maximal_events () const
 Returns the list of maximal events in this area, i.e., those not having any successors within the area. More...
 
- Public Member Functions inherited from EventArea
 EventArea ()
 
 EventArea (EventArea *original)
 
virtual ~EventArea ()
 
const EventAreaPtr get_next_area () const
 
EventAreaget_previous_area () const
 
Instanceget_instance () const
 
void set_instance (Instance *instance)
 
const Coordinateget_begin_height () const
 
void set_begin_height (const Coordinate &begin_height)
 
const Coordinateget_end_height () const
 
void set_end_height (const Coordinate &end_height)
 
Size get_height () const
 
Size get_width () const
 
void set_width (const Size &width)
 
template<typename EventType >
boost::intrusive_ptr< EventType > add_event (const boost::intrusive_ptr< EventType > &e)
 Puts an event in this area as a maximal event. The event itself is returned. More...
 
template<typename EventType >
boost::intrusive_ptr< EventType > add_event (EventType *e)
 Puts an event in this area as a maximal event. The event itself is returned. More...
 
- Public Member Functions inherited from MscElementTmpl< EventArea >
int get_visual_style () const
 
void set_visual_style (int visual_style)
 
MscElementget_general_original () const
 See MscElementTmpl for details about attribute original. More...
 
void set_general_original (MscElement *original)
 See MscElementTmpl for details about attribute original. More...
 
EventAreaget_original () const
 
void set_original (EventArea *e)
 
void set_original (boost::intrusive_ptr< EventArea > &e)
 
virtual ~MscElementTmpl ()
 
- Public Member Functions inherited from MscElement
bool is_attribute_set (const std::string &name) const
 Finds out whether attribute with specified name is set or not. More...
 
template<class T >
T & get_attribute (const std::string &name, const T &def)
 Returns dynamic attribute of MscElement. More...
 
template<class T >
T & get_attribute (const std::string &name, const T &def, bool &status)
 Returns dynamic attribute of MscElement. More...
 
template<class T >
void set_attribute (const std::string &name, const T &val)
 Sets dynamic attribute of MscElement. More...
 
template<class T >
void remove_attribute (const std::string &name)
 Removes attribute of MscElement. More...
 
std::set< std::stringget_attribute_names () const
 List all attributes of MscElement. More...
 
enum MarkType get_marked () const
 
void set_marked (enum MarkType marked=MARKED)
 
MscColor get_color () const
 
void set_color (MscColor color)
 
void clear_color ()
 
virtual ~MscElement ()
 

Protected Member Functions

EventPtr add_event_impl (const EventPtr &e)
 
- Protected Member Functions inherited from MscElementTmpl< EventArea >
 MscElementTmpl ()
 
 MscElementTmpl (EventArea *original)
 Creates MscElement referencing the original one. More...
 
- Protected Member Functions inherited from MscElement
 MscElement ()
 

Private Attributes

EventPtrList m_events
 

Additional Inherited Members

- Protected Attributes inherited from EventArea
Coordinate m_begin_height
 
Coordinate m_end_height
 
Size m_width
 
Instancem_instance
 
- Protected Attributes inherited from MscElementTmpl< EventArea >
int m_visual_style
 Visual style of the shape. More...
 
boost::intrusive_ptr< EventAream_original
 Pointer to original version of MscElement. More...
 

Detailed Description

EventArea whose events are ordered linearly as they follow each other.

Definition at line 28 of file StrictOrderArea.h.

Constructor & Destructor Documentation

StrictOrderArea::StrictOrderArea ( )
inline

Definition at line 37 of file StrictOrderArea.h.

StrictOrderArea::StrictOrderArea ( StrictOrderArea original)
inline

Definition at line 41 of file StrictOrderArea.h.

virtual StrictOrderArea::~StrictOrderArea ( )
inlinevirtual

Definition at line 45 of file StrictOrderArea.h.

Member Function Documentation

void StrictOrderArea::add_event ( const EventPtr e,
Event predecessor 
)

Adds an event after a given event in this area, or at the beginning of the area if NULL is passed.

Definition at line 23 of file StrictOrderArea.cpp.

References m_events.

EventPtr StrictOrderArea::add_event_impl ( const EventPtr e)
inlineprotectedvirtual

Implements EventArea.

Definition at line 86 of file StrictOrderArea.h.

const EventPtrList& StrictOrderArea::get_events ( ) const
inline
const EventPtr StrictOrderArea::get_first_event ( ) const
inline

Returns the first event in the area, or intrusive NULL-pointer if the area is empty.

Definition at line 52 of file StrictOrderArea.h.

Referenced by check_node(), Configuration::Configuration(), instance_diff(), and MonteCarlo::BMscDealer::traverse_area().

const EventPtr StrictOrderArea::get_last_event ( ) const
inline

Returns the last event in the area, or intrusive NULL-pointer if the area is empty.

Definition at line 65 of file StrictOrderArea.h.

Referenced by get_predecessor(), and LayoutOptimizer::process().

EventPList StrictOrderArea::get_maximal_events ( ) const
inlinevirtual

Returns the list of maximal events in this area, i.e., those not having any successors within the area.

Every event is present at most once in the returned list - the list is rather an ordered set.

In case there are no events, an empty set is returned.

Note that a new list is returned. Thus, if used for iteration, begin() and end() has both to be invoked on the same set.

Implements EventArea.

Definition at line 118 of file StrictOrderArea.h.

References EventArea::is_empty().

EventPList StrictOrderArea::get_minimal_events ( ) const
inlinevirtual

Returns the list of minimal events in this area, i.e., those not having any predecessors within the area, in the order of their insertion to the area.

Every event is present at most once in the returned list - the list is rather an ordered set.

In case there are no events, an empty list is returned.

Note that a new list is returned. Thus, if used for iteration, begin() and end() has both to be invoked on the same list.

Implements EventArea.

Definition at line 108 of file StrictOrderArea.h.

References EventArea::is_empty().

EventPSet StrictOrderArea::get_predecessor_events ( const Event e) const
virtual

Returns predecessor events of a given event within this area, or an empty set if this is a minimal event.

Implements EventArea.

Definition at line 38 of file StrictOrderArea.cpp.

References m_events, and result.

EventPSet StrictOrderArea::get_successor_events ( const Event e) const
virtual

Returns successor events of a given event within this area, or an empty set if this is a maximal event.

Implements EventArea.

Definition at line 52 of file StrictOrderArea.cpp.

References m_events, and result.

bool StrictOrderArea::is_empty ( ) const
inlinevirtual

Returns true iff the event area doesn't contain any Events.

Implements EventArea.

Definition at line 80 of file StrictOrderArea.h.

Referenced by MonteCarlo::BMscDealer::traverse_area().

void StrictOrderArea::remove_event ( Event e)
virtual

Removes a given event from the area.

Implements EventArea.

Definition at line 63 of file StrictOrderArea.cpp.

References m_events.

Member Data Documentation

EventPtrList StrictOrderArea::m_events
private

The list of events in the area.

Definition at line 33 of file StrictOrderArea.h.

Referenced by add_event(), get_predecessor_events(), get_successor_events(), and remove_event().


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

SourceForge.net Logo
Generated on Fri Jan 15 2016 16:26:59 for Sequence Chart Studio by  doxygen