List of clients.
More...
#include <JClientList.hh>
List of clients.
Definition at line 22 of file JClientList.hh.
KM3NETDAQ::JClientList::JClientList |
( |
| ) |
|
|
inline |
Default constructor.
Definition at line 66 of file JClientList.hh.
const JComparator comparator
Insert client.
- Parameters
-
- Returns
- iterator to client and true if inserted; else false
Definition at line 78 of file JClientList.hh.
80 iterator i = std::lower_bound(this->begin(), this->end(), client, comparator);
82 if (i == this->end() ||
comparator(client, *i)) {
86 return std::make_pair(i,
true);
90 return std::make_pair(i,
false);
const JComparator comparator
Find client.
- Parameters
-
- Returns
- iterator to client
Definition at line 101 of file JClientList.hh.
103 iterator i = std::lower_bound(this->begin(), this->end(), client, comparator);
105 if (i != this->end() && !
comparator(*i, client))
const JComparator comparator
iterator KM3NETDAQ::JClientList::find |
( |
const std::string & |
buffer | ) |
|
|
inline |
Find client by its full name.
- Parameters
-
buffer | full name of client (possibly followed by more text) |
- Returns
- position of client (or end)
Definition at line 118 of file JClientList.hh.
122 iterator i = std::lower_bound(this->begin(), this->end(), full_name, comparator);
124 if (i != this->end() && !
comparator(*i, full_name))
const JComparator comparator
std::string getFullName(const std::string &hostname, const std::string &name)
Get full name of run control client.
void KM3NETDAQ::JClientList::start |
( |
| ) |
|
|
inline |
Start processes.
Definition at line 134 of file JClientList.hh.
136 for (iterator i = this->begin(); i != this->end(); ++i) {
137 if (i->getMode() == JClient::ACTIVE) {
void KM3NETDAQ::JClientList::stop |
( |
const int |
signal = -9 | ) |
|
|
inline |
Stop processes.
- Parameters
-
Definition at line 149 of file JClientList.hh.
151 for (iterator i = this->begin(); i != this->end(); ++i) {
152 if (i->getBorn() > i->getDied()) {
unsigned int KM3NETDAQ::JClientList::count |
( |
const JClient::JMode |
mode | ) |
const |
|
inline |
Get number of clients with given mode.
- Parameters
-
- Returns
- number of clients
Definition at line 165 of file JClientList.hh.
169 for (const_iterator i = this->begin(); i != this->end(); ++i) {
170 if (i->getMode() == mode) {
unsigned int KM3NETDAQ::JClientList::count |
( |
| ) |
const |
|
inline |
Get number of active clients with born count exceeding died count.
- Returns
- number of clients
Definition at line 184 of file JClientList.hh.
188 for (const_iterator i = this->begin(); i != this->end(); ++i) {
189 if (i->getMode() == JClient::ACTIVE && i->getBorn() > i->getDied()) {
unsigned int KM3NETDAQ::JClientList::count |
( |
const CHSM::state & |
state | ) |
const |
|
inline |
Get number of active clients in given state.
- Parameters
-
- Returns
- number of clients
Definition at line 204 of file JClientList.hh.
208 for (const_iterator i = this->begin(); i != this->end(); ++i) {
209 if (i->getMode() == JClient::ACTIVE && i->getStatename() ==
getStateName(state.name())) {
std::string getStateName(const std::string &name)
Get name of state.
The documentation for this class was generated from the following file: