#include <BESContainerStorageVolatile.h>
Inheritance diagram for BESContainerStorageVolatile:
Public Types | |
typedef map< string, BESContainer * >::const_iterator | Container_citer |
typedef map< string, BESContainer * >::iterator | Container_iter |
Public Member Functions | |
BESContainerStorageVolatile (const string &n) | |
create an instance of this persistent store with the given name. | |
virtual | ~BESContainerStorageVolatile () |
virtual void | look_for (BESContainer &d) |
looks for the specified container using the given name | |
virtual void | add_container (const string &s_name, const string &r_name, const string &type) |
adds a container with the provided information | |
virtual bool | del_container (const string &s_name) |
removes a container with the given symbolic name | |
virtual bool | del_containers () |
removes all container | |
virtual void | show_containers (BESInfo &info) |
show information for each container in this persistent store | |
virtual void | dump (ostream &strm) const |
dumps information about this object | |
virtual const string & | get_name () const |
retrieve the name of this persistent store | |
Protected Attributes | |
string | _root_dir |
string | _my_name |
This implementation of BESContainerStorage stores volatile containers for the duration of this process. A list of containers is stored in the object. The look_for method simply looks for the specified symbolic name in the list of containers and returns if a match is found. Containers can be added to this instance as long as the symbolic name doesn't already exist.
Definition at line 57 of file BESContainerStorageVolatile.h.
typedef map< string, BESContainer * >::const_iterator BESContainerStorageVolatile::Container_citer |
Definition at line 67 of file BESContainerStorageVolatile.h.
typedef map< string, BESContainer * >::iterator BESContainerStorageVolatile::Container_iter |
Definition at line 68 of file BESContainerStorageVolatile.h.
BESContainerStorageVolatile::BESContainerStorageVolatile | ( | const string & | n | ) |
create an instance of this persistent store with the given name.
Creates an instances of BESContainerStorageVolatile with the given name.
n | name of this persistent store |
Definition at line 46 of file BESContainerStorageVolatile.cc.
References _root_dir, BESKeys::get_key(), and TheBESKeys::TheKeys().
Here is the call graph for this function:
BESContainerStorageVolatile::~BESContainerStorageVolatile | ( | ) | [virtual] |
Definition at line 59 of file BESContainerStorageVolatile.cc.
void BESContainerStorageVolatile::look_for | ( | BESContainer & | d | ) | [virtual] |
looks for the specified container using the given name
If a match is made with the symbolic name found in the container then the information is stored in the passed container object and the is_valid flag is set to true. If not found, then is_valid is set to false.
d | container to look for and, if found, store the information in. |
Implements BESContainerStorage.
Definition at line 72 of file BESContainerStorageVolatile.cc.
References BESContainer::get_symbolic_name(), BESContainer::set_container_type(), BESContainer::set_real_name(), and BESContainer::set_valid_flag().
Referenced by pvolT::run().
Here is the call graph for this function:
void BESContainerStorageVolatile::add_container | ( | const string & | s_name, | |
const string & | r_name, | |||
const string & | type | |||
) | [virtual] |
adds a container with the provided information
This method adds a container to the persistence store with the specified information.
s_name | symbolic name for the container | |
r_name | real name for the container | |
type | type of data represented by this container |
Implements BESContainerStorage.
Reimplemented in BESContainerStorageCatalog.
Definition at line 92 of file BESContainerStorageVolatile.cc.
References _root_dir, BESContainer::set_container_type(), and BESContainer::set_real_name().
Referenced by BESContainerStorageCatalog::add_container(), and pvolT::run().
Here is the call graph for this function:
bool BESContainerStorageVolatile::del_container | ( | const string & | s_name | ) | [virtual] |
removes a container with the given symbolic name
This method removes a container to the persistence store with the given symbolic name. It deletes the container.
s_name | symbolic name for the container |
Implements BESContainerStorage.
Definition at line 134 of file BESContainerStorageVolatile.cc.
Referenced by pvolT::run().
bool BESContainerStorageVolatile::del_containers | ( | ) | [virtual] |
removes all container
This method removes all containers from the persistent store. It does not delete the real data behind the container.
Implements BESContainerStorage.
Definition at line 157 of file BESContainerStorageVolatile.cc.
void BESContainerStorageVolatile::show_containers | ( | BESInfo & | info | ) | [virtual] |
show information for each container in this persistent store
For each container in this persistent store, add infomation about each of those containers. The information added to the information object includes a line for each container within this persistent store which includes the symbolic name, the real name, and the data type, separated by commas.
In the case of this persistent store information from each container added to the volatile list is added to the information object.
info | object to store the container and persistent store information |
Implements BESContainerStorage.
Definition at line 187 of file BESContainerStorageVolatile.cc.
References BESInfo::add_tag(), BESInfo::begin_tag(), BESInfo::end_tag(), BESContainer::get_container_type(), BESContainerStorage::get_name(), BESContainer::get_real_name(), and BESContainer::get_symbolic_name().
Referenced by pvolT::run().
Here is the call graph for this function:
void BESContainerStorageVolatile::dump | ( | ostream & | strm | ) | const [virtual] |
dumps information about this object
Displays the pointer value of this instance along with information about the containers stored in this volatile list.
strm | C++ i/o stream to dump the information to |
Implements BESContainerStorage.
Reimplemented in BESContainerStorageCatalog.
Definition at line 213 of file BESContainerStorageVolatile.cc.
References BESContainerStorage::get_name(), BESIndent::Indent(), BESIndent::LMarg(), and BESIndent::UnIndent().
Here is the call graph for this function:
virtual const string& BESContainerStorage::get_name | ( | ) | const [inline, virtual, inherited] |
retrieve the name of this persistent store
Definition at line 86 of file BESContainerStorage.h.
References BESContainerStorage::_my_name.
Referenced by BESContainerStorageList::add_persistence(), dump(), BESContainerStorageFile::dump(), BESContainerStorageCatalog::dump(), show_containers(), and BESContainerStorageFile::show_containers().
string BESContainerStorageVolatile::_root_dir [protected] |
Definition at line 62 of file BESContainerStorageVolatile.h.
Referenced by add_container(), BESContainerStorageCatalog::BESContainerStorageCatalog(), and BESContainerStorageVolatile().
string BESContainerStorage::_my_name [protected, inherited] |