Main Page | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

AMOS::BankStreamSet_t Class Reference

A non-redundant, complete collection of AMOS banks. More...

#include <universals_AMOS.hh>

List of all members.

Public Member Functions

 BankStreamSet_t ()
 Constructs a BankStreamSet_t w/ default banks.
 ~BankStreamSet_t ()
 Destroys a UniveralSet_t and closes its contained banks.
iterator begin ()
 Returns an iterator to the beginning of the set.
const_iterator begin () const
void clearAll ()
 Issues a clear command to each bank in the set.
void closeAll ()
 Issues a close command to each bank in the set.
iterator end ()
 Returns an iterator to the end of the set.
const_iterator end () const
bool exists (NCode_t ncode)
 Checks if a bank with a given NCode exists in the set.
Size_t getSize ()
 Returns the number of known AMOS banks.
BankStream_toperator[] (NCode_t ncode)
 Returns a reference to the bank with the given NCode.
const BankStream_toperator[] (NCode_t ncode) const
BankStream_toperator[] (const std::string &ncode)
const BankStream_toperator[] (const std::string &ncode) const


Detailed Description

A non-redundant, complete collection of AMOS banks.

Provides a non-redundant, complete collection of static AMOS banks accessible by their NCode and iteration. Useful when all possible AMOS banks are required, but the exact makeup of banks is unknown. Banks stored in this set are static, and only destruced when the class is destructed. Banks are stored in order that will preserve the def-before-ref rule - meaning two banks A,B where B has a link to A will always appear in the order A,B when iterating through the set.

Definition at line 432 of file universals_AMOS.hh.


Constructor & Destructor Documentation

BankStreamSet_t::BankStreamSet_t  ) 
 

Constructs a BankStreamSet_t w/ default banks.

Definition at line 122 of file universals_AMOS.cc.

References begin(), and end().

BankStreamSet_t::~BankStreamSet_t  ) 
 

Destroys a UniveralSet_t and closes its contained banks.

Definition at line 142 of file universals_AMOS.cc.

References begin(), and end().


Member Function Documentation

const_iterator AMOS::BankStreamSet_t::begin  )  const [inline]
 

Definition at line 516 of file universals_AMOS.hh.

References begin().

iterator AMOS::BankStreamSet_t::begin  )  [inline]
 

Returns an iterator to the beginning of the set.

Iterator on all the banks in the set. Operates just like a std::vector iterator, however it does not support iterator addition/subtraction or reverse iteration. Banks will always be ordered definition-before-reference, meaning if B refers to A, A will always appear before B when iterating forward.

Returns:
An iterator to the beginning of the set
Definition at line 515 of file universals_AMOS.hh.

Referenced by BankStreamSet_t(), begin(), clearAll(), closeAll(), and ~BankStreamSet_t().

void BankStreamSet_t::clearAll  ) 
 

Issues a clear command to each bank in the set.

Returns:
void
Definition at line 153 of file universals_AMOS.cc.

References begin(), and end().

void BankStreamSet_t::closeAll  ) 
 

Issues a close command to each bank in the set.

Returns:
void
Definition at line 161 of file universals_AMOS.cc.

References begin(), and end().

const_iterator AMOS::BankStreamSet_t::end  )  const [inline]
 

Definition at line 541 of file universals_AMOS.hh.

References end().

iterator AMOS::BankStreamSet_t::end  )  [inline]
 

Returns an iterator to the end of the set.

Returns:
An iterator to the end of the set
Definition at line 540 of file universals_AMOS.hh.

References end().

Referenced by BankStreamSet_t(), clearAll(), closeAll(), end(), exists(), operator[](), and ~BankStreamSet_t().

bool AMOS::BankStreamSet_t::exists NCode_t  ncode  )  [inline]
 

Checks if a bank with a given NCode exists in the set.

Returns:
true if it exists, false otherwise
Definition at line 549 of file universals_AMOS.hh.

References end(), and AMOS::NCode_t.

Size_t AMOS::BankStreamSet_t::getSize  )  [inline]
 

Returns the number of known AMOS banks.

Returns:
The number of banks in the set
Definition at line 560 of file universals_AMOS.hh.

References AMOS::Size_t.

const BankStream_t& AMOS::BankStreamSet_t::operator[] const std::string &  ncode  )  const [inline]
 

Definition at line 602 of file universals_AMOS.hh.

References AMOS::Encode(), and operator[]().

BankStream_t& AMOS::BankStreamSet_t::operator[] const std::string &  ncode  )  [inline]
 

Definition at line 595 of file universals_AMOS.hh.

References AMOS::Encode(), and operator[]().

const BankStream_t& AMOS::BankStreamSet_t::operator[] NCode_t  ncode  )  const [inline]
 

Definition at line 584 of file universals_AMOS.hh.

References AMOS_THROW_ARGUMENT, AMOS::Decode(), end(), and AMOS::NCode_t.

BankStream_t& AMOS::BankStreamSet_t::operator[] NCode_t  ncode  )  [inline]
 

Returns a reference to the bank with the given NCode.

Precondition:
The NCode exists in the set
Exceptions:
ArgumentException_t 
Returns:
Pointer to the bank with the given NCode
Definition at line 573 of file universals_AMOS.hh.

References AMOS_THROW_ARGUMENT, AMOS::Decode(), end(), and AMOS::NCode_t.

Referenced by operator[]().


The documentation for this class was generated from the following files:
Generated on Tue May 17 15:19:52 2005 for libAMOS by doxygen 1.3.8