|
SIMLIB/C++
3.07
|
priority queue More...
#include <simlib.h>


Public Types | |
| typedef List::iterator | iterator |
Public Types inherited from simlib3::SimObject | |
| enum | _Flags { _CLEAR_ALL_FLAGS = 0, _ALLOCATED_FLAG = 1<<0, _EVAL_FLAG = 1<<1, _HAS_NAME_FLAG = 1<<2 } |
Public Member Functions | |
| Queue () | |
| Queue (const char *_name) | |
| ~Queue () | |
| virtual void | Output () const override |
| print statistics More... | |
| operator Queue * () | |
| iterator | begin () |
| iterator | end () |
| Entity * | front () |
| Entity * | back () |
| void | clear () |
| initialize More... | |
| void | Clear () |
| bool | Empty () |
| unsigned | Length () |
| virtual void | Insert (Entity *e) |
| void | InsFirst (Entity *e) |
| void | InsLast (Entity *e) |
| void | PredIns (Entity *e, iterator pos) |
| void | PostIns (Entity *e, iterator pos) |
| virtual Entity * | Get (iterator pos) |
| remove at position More... | |
| Entity * | GetFirst () |
| Entity * | GetLast () |
Public Member Functions inherited from simlib3::List | |
| List () | |
| List (const char *_name) | |
| ~List () | |
| void | InsFirst (Link *e) |
| void | InsLast (Link *e) |
| void | PredIns (Link *e, iterator pos) |
| void | PostIns (Link *e, iterator pos) |
| Link * | GetFirst () |
| remove first More... | |
| Link * | GetLast () |
| remove last More... | |
| unsigned | size () const |
| iterator | begin () |
| iterator | end () |
| Link * | front () |
| Link * | back () |
| bool | empty () |
| void | clear () |
Public Member Functions inherited from simlib3::Link | |
| Link () | |
| virtual | ~Link () |
| virtual void | Into (List *l) |
| insert last More... | |
| virtual void | Out () |
| remove from list More... | |
| List * | Where () |
| where is linked More... | |
| virtual bool | isInQueue () |
| present in queue More... | |
Public Member Functions inherited from simlib3::SimObject | |
| bool | TestAndSetFlag (bool new_value, unsigned n) |
| internal method for flag manipulation is used for algebraic loop checking in continuous blocks More... | |
| SimObject () | |
| constructor More... | |
| virtual | ~SimObject () |
| virtual destructor More... | |
| void * | operator new (size_t size) |
| allocate object, set _flags More... | |
| void | operator delete (void *ptr) |
| deallocate object More... | |
| void * | operator new[] (size_t size)=delete |
| void | operator delete[] (void *ptr)=delete |
| bool | isAllocated () const |
| virtual std::string | Name () const |
| get object name More... | |
| bool | HasName () const |
| void | SetName (const std::string &name) |
| assign the name More... | |
Public Attributes | |
| TStat | StatN |
| Stat | StatDT |
Friends | |
| class | Facility |
| class | Store |
Additional Inherited Members | |
Protected Member Functions inherited from simlib3::Link | |
| Link (Link *p, Link *s, List *h) | |
Protected Attributes inherited from simlib3::SimObject | |
| unsigned | _flags |
| bool flags for internal use (TODO bitfield?) More... | |
|
explicit |
Definition at line 34 of file queue.cc.
References Dprintf, and simlib3::SimObject::SetName().
| simlib3::Queue::~Queue | ( | ) |
Definition at line 43 of file queue.cc.
References Dprintf, and simlib3::SimObject::Name().
|
inline |
Definition at line 702 of file simlib.h.
References simlib3::List::back().
|
inline |
Definition at line 699 of file simlib.h.
References simlib3::List::begin().
Referenced by GetFirst(), Insert(), InsFirst(), simlib3::Store::Leave(), simlib3::Facility::QueueIn(), and simlib3::Facility::QueueIn2().
| void simlib3::Queue::clear | ( | ) |
initialize
Definition at line 145 of file queue.cc.
References simlib3::Stat::Clear(), simlib3::TStat::Clear(), simlib3::List::clear(), Dprintf, simlib3::SimObject::Name(), simlib3::SIMLIB_create_tmp_name(), StatDT, and StatN.
|
inline |
Definition at line 706 of file simlib.h.
Referenced by simlib3::Facility::Clear(), simlib3::Store::Clear(), and simlib3::Semaphore::Clear().
|
inline |
Definition at line 700 of file simlib.h.
References simlib3::List::end().
Referenced by GetLast(), Insert(), InsLast(), simlib3::Store::Leave(), PostIns(), simlib3::Facility::QueueIn(), and simlib3::Facility::QueueIn2().
|
inline |
Definition at line 701 of file simlib.h.
References simlib3::List::front().
Referenced by simlib3::Facility::Release(), and simlib3::Semaphore::V().
remove at position
Reimplemented from simlib3::List.
Definition at line 133 of file queue.cc.
References simlib3::Entity::_MarkTime, Dprintf, simlib3::List::Get(), simlib3::TStat::n, simlib3::SimObject::Name(), simlib3::List::size(), StatDT, StatN, and simlib3::Time.
Referenced by GetFirst(), GetLast(), and simlib3::Semaphore::P().
| Entity * simlib3::Queue::GetFirst | ( | ) |
Definition at line 113 of file queue.cc.
References begin(), Dprintf, Get(), and simlib3::SimObject::Name().
Referenced by simlib3::Facility::Release().
| Entity * simlib3::Queue::GetLast | ( | ) |
|
virtual |
Definition at line 50 of file queue.cc.
References begin(), Dprintf, end(), simlib3::SimObject::Name(), PredIns(), and simlib3::Entity::Priority.
Referenced by simlib3::Process::Into(), simlib3::Semaphore::P(), simlib3::Entity::Passivate(), and simlib3::Store::QueueIn().
| void simlib3::Queue::InsFirst | ( | Entity * | e | ) |
| void simlib3::Queue::InsLast | ( | Entity * | e | ) |
|
inline |
Definition at line 708 of file simlib.h.
References simlib3::SQS::Get(), and simlib3::SQS::GetFirst().
|
overridevirtual |
print statistics
Reimplemented from simlib3::List.
Definition at line 116 of file output2.cc.
References simlib3::SimObject::Name(), simlib3::Print(), and simlib3::Time.
Referenced by simlib3::Facility::Output().
Definition at line 91 of file queue.cc.
References Dprintf, end(), simlib3::SimObject::Name(), PredIns(), and SIMLIB_internal_error.
Definition at line 102 of file queue.cc.
References simlib3::Entity::_MarkTime, Dprintf, simlib3::SimObject::Name(), simlib3::List::PredIns(), simlib3::List::size(), StatN, and simlib3::Time.
Referenced by Insert(), InsFirst(), InsLast(), PostIns(), simlib3::Facility::QueueIn(), and simlib3::Facility::QueueIn2().
| Stat simlib3::Queue::StatDT |
| TStat simlib3::Queue::StatN |
1.8.13