Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members  

CdbRooRoCollectionAddressR Class Reference

A persistent collection "address". More...

List of all members.

Public Types

enum  {
  SCHEMA_FIRST = 0, SCHEMA_REGISTRY = SCHEMA_FIRST, SCHEMA_REGULAR = 1, SCHEMA_PARTITIONABLE = 2,
  SCHEMA_LAST = SCHEMA_PARTITIONABLE
}

Public Member Functions

 CdbRooRoCollectionAddressR ()
 The default constructor.

virtual ~CdbRooRoCollectionAddressR ()
 The destructor.

 CdbRooRoCollectionAddressR (const CdbRooRoCollectionAddressR &theOther)
 The copy constructor.

CdbRooRoCollectionAddressR & operator= (const CdbRooRoCollectionAddressR &theOther)
 The assignment operator.

std::string name () const
UShort_t origin () const
UShort_t schema () const
UShort_t cluster () const
UShort_t partition () const
UShort_t increment () const
bool isValid () const
 Check the status of an address.

std::string toString () const
 Get a string representation of the identifier.


Static Public Member Functions

CdbRooRoCollectionAddressR createRegistry (const std::string &theCollectionName, UShort_t theOrigin)
 A factory method for "REGISTRY" collection addresses.

CdbRooRoCollectionAddressR createRegular (const std::string &theCollectionName, UShort_t theOrigin, UShort_t theCluster, UShort_t theIncrement)
 A factory method for "REGULAR" collection addresses.

CdbRooRoCollectionAddressR createPartitionable (const std::string &theCollectionName, UShort_t theOrigin, UShort_t theCluster, UShort_t thePartition, UShort_t theIncrement)
 A factory method for "PARTITIONABLE" collection addresses.

CdbRooRoCollectionAddressR createSubCollection (const CdbRooRoCollectionAddressR &theCollection, const std::string &theSuffix)
 Create a subcollection.


Detailed Description

A persistent collection "address".

In general, the address is defined as follows:

--:

For the current implementation the full address has the following layout:

16-bit 16-bit 16-bit 16-bit 16-bit std::string -------- -------- --------- ----------- ----------- ----------------- ----:

Where only two address schemes are supported:

=0 corresponds to "REGISTRY" collections. All fields following the one are ignored.

=1 corresponds to "REGULAR" collections. The field is ignored

=2 corresponds to "PARTITIONABLE" collections.

Object would be printed as (for example):

"o0.System.OriginCollection-0-0-0-0" (orign collection at the MASTER's "REGISTRY") "o256.c0.i1.MetaData.15-1-0-0-1" (metadata of the "REGULAR" condition's collection) "o257.c0.p20.i0.Objects.15-2-0-20-0" (payload of the "PARTITIONABLE" condition's collection)

Definition at line 42 of file CdbRooRoCollectionAddressR.rdl.


Member Enumeration Documentation

anonymous enum
 

Enumeration values:
SCHEMA_FIRST 
SCHEMA_REGISTRY 
SCHEMA_REGULAR 
SCHEMA_PARTITIONABLE 
SCHEMA_LAST 

Definition at line 46 of file CdbRooRoCollectionAddressR.rdl.


Constructor & Destructor Documentation

CdbRooRoCollectionAddressR::CdbRooRoCollectionAddressR   [inline]
 

The default constructor.

It will construct an invalid object address. Use schema specific functory methods defined above instead.

See also:
CdbRooRoCollectionAddressR::isValid()

Definition at line 136 of file CdbRooRoCollectionAddressR.rdl.

Referenced by createPartitionable(), createRegistry(), and createRegular().

virtual CdbRooRoCollectionAddressR::~CdbRooRoCollectionAddressR   [inline, virtual]
 

The destructor.

Definition at line 146 of file CdbRooRoCollectionAddressR.rdl.

CdbRooRoCollectionAddressR::CdbRooRoCollectionAddressR const CdbRooRoCollectionAddressR &    theOther [inline]
 

The copy constructor.

Definition at line 151 of file CdbRooRoCollectionAddressR.rdl.


Member Function Documentation

UShort_t CdbRooRoCollectionAddressR::cluster   const [inline]
 

Definition at line 213 of file CdbRooRoCollectionAddressR.rdl.

Referenced by CdbRooRoFileUtils::findDatabase().

CdbRooRoCollectionAddressR CdbRooRoCollectionAddressR::createPartitionable const std::string &    theCollectionName,
UShort_t    theOrigin,
UShort_t    theCluster,
UShort_t    thePartition,
UShort_t    theIncrement
[inline, static]
 

A factory method for "PARTITIONABLE" collection addresses.

Definition at line 92 of file CdbRooRoCollectionAddressR.rdl.

References CdbRooRoCollectionAddressR().

CdbRooRoCollectionAddressR CdbRooRoCollectionAddressR::createRegistry const std::string &    theCollectionName,
UShort_t    theOrigin
[inline, static]
 

A factory method for "REGISTRY" collection addresses.

Definition at line 56 of file CdbRooRoCollectionAddressR.rdl.

References CdbRooRoCollectionAddressR().

CdbRooRoCollectionAddressR CdbRooRoCollectionAddressR::createRegular const std::string &    theCollectionName,
UShort_t    theOrigin,
UShort_t    theCluster,
UShort_t    theIncrement
[inline, static]
 

A factory method for "REGULAR" collection addresses.

Definition at line 72 of file CdbRooRoCollectionAddressR.rdl.

References CdbRooRoCollectionAddressR().

CdbRooRoCollectionAddressR CdbRooRoCollectionAddressR::createSubCollection const CdbRooRoCollectionAddressR &    theCollection,
const std::string &    theSuffix
[inline, static]
 

Create a subcollection.

Subcollections are residing at the same logical file where the main collections are, they just have the specified suffic appended by the name of the main collection.

Definition at line 117 of file CdbRooRoCollectionAddressR.rdl.

References _name, and isValid().

Referenced by CdbRooRoRevCollectionR::storeSubCollectionsAt(), and CdbRooRoOiCollectionR::storeSubCollectionsAt().

UShort_t CdbRooRoCollectionAddressR::increment   const [inline]
 

Definition at line 215 of file CdbRooRoCollectionAddressR.rdl.

Referenced by CdbRooRoFileUtils::findDatabase(), and toString().

bool CdbRooRoCollectionAddressR::isValid   const [inline]
 

Check the status of an address.

An address is considered as a NON-valid one only when all its fileds are constructed using their default values.

See also:
CdbRooRoCollectionAddressR::CdbRooRoCollectionAddressR()

Definition at line 225 of file CdbRooRoCollectionAddressR.rdl.

References SCHEMA_LAST.

Referenced by createSubCollection(), CdbRooRoFileUtils::findDatabase(), CdbRooRoFileUtils::findTree(), CdbRooRoPersistentCollectionR::storeAt(), and toString().

std::string CdbRooRoCollectionAddressR::name   const [inline]
 

Definition at line 209 of file CdbRooRoCollectionAddressR.rdl.

Referenced by CdbRooRoVectorCollectionR< T, STORAGE_POLICY >::storeSubCollectionsAt(), and toString().

CdbRooRoCollectionAddressR& CdbRooRoCollectionAddressR::operator= const CdbRooRoCollectionAddressR &    theOther [inline]
 

The assignment operator.

Definition at line 162 of file CdbRooRoCollectionAddressR.rdl.

References _cluster, _increment, _name, _origin, _partition, and _schema.

UShort_t CdbRooRoCollectionAddressR::origin   const [inline]
 

Definition at line 211 of file CdbRooRoCollectionAddressR.rdl.

Referenced by CdbRooRoFileUtils::findDatabase().

UShort_t CdbRooRoCollectionAddressR::partition   const [inline]
 

Definition at line 214 of file CdbRooRoCollectionAddressR.rdl.

Referenced by CdbRooRoFileUtils::findDatabase(), and toString().

UShort_t CdbRooRoCollectionAddressR::schema   const [inline]
 

Definition at line 212 of file CdbRooRoCollectionAddressR.rdl.

Referenced by CdbRooRoFileUtils::findDatabase().

std::string CdbRooRoCollectionAddressR::toString   const
 

Get a string representation of the identifier.

See also:
CdbRooRoCollectionAddressR

Definition at line 15 of file CdbRooRoCollectionAddressR.cc.

References increment(), isValid(), name(), partition(), and CdbStringUtils::toString().

Referenced by operator<<().


The documentation for this class was generated from the following files:
Generated on Mon Dec 5 18:22:24 2005 for CDB by doxygen1.3-rc3