ATLAS Offline Software
|
An implicit collection implementation of the ICollection interface. More...
#include <ImplicitCollection.h>
Public Types | |
typedef Gaudi::PluginService::Factory< ICollection *(const ICollectionDescription *, ICollection::OpenMode, ISession *)> | Factory |
enum | OpenMode { CREATE, CREATE_AND_OVERWRITE, UPDATE, READ } |
Enumeration of the possible open modes of the collection. More... | |
Public Member Functions | |
ImplicitCollection (ISession *session, const std::string &connection, const std::string &name, ICollection::OpenMode mode) | |
Constructor - old style Throws POOL exception. More... | |
ImplicitCollection (const ICollectionDescription *description, ICollection::OpenMode mode, ISession *session) | |
Constructor compying to the new Collections API parameters as above, but name and connection passed in description. More... | |
~ImplicitCollection () | |
Destructor. More... | |
ImplicitCollection (const ImplicitCollection &)=delete | |
ImplicitCollection & | operator= (const ImplicitCollection &)=delete |
virtual ICollection::OpenMode | openMode () const |
Return openMode. More... | |
ImplicitCollectionIterator * | select (const std::string &primaryQuery="", std::string secondaryQuery="", std::string options="") |
Method that returns collection's iterator Throws POOL exception. More... | |
void | commit (bool reopen=false) |
Commits the last changes made to the collection. Will always return true. More... | |
void | rollback () |
Aborts the last changes made to the collection. Will always return true. More... | |
void | close () |
no-op at the moment More... | |
void | open () |
no-op at the moment More... | |
bool | isOpen () const |
Checks if the collection is open. More... | |
virtual const ICollectionDescription & | description () const |
Returns an object used to describe the collection properties. More... | |
virtual ICollectionSchemaEditor & | schemaEditor () |
Returns an object used to modify the collection schema. More... | |
virtual ICollectionDataEditor & | dataEditor () |
Returns an object used to add, update or delete rows of the collection. More... | |
virtual ICollectionQuery * | newQuery () |
Returns an object used to query the collection. More... | |
Protected Member Functions | |
void | open (ICollection::OpenMode mode, ISession *session) |
Private Attributes | |
IContainer * | m_container |
The underlying container handle. More... | |
CollectionDescription | m_description |
An implicit collection implementation of the ICollection interface.
Definition at line 26 of file ImplicitCollection.h.
typedef Gaudi::PluginService::Factory<ICollection*( const ICollectionDescription*, ICollection::OpenMode, ISession*)> pool::ImplicitCollection::Factory |
Definition at line 30 of file ImplicitCollection.h.
|
inherited |
Enumeration of the possible open modes of the collection.
Enumerator | |
---|---|
CREATE | |
CREATE_AND_OVERWRITE | |
UPDATE | |
READ |
Definition at line 27 of file ICollection.h.
pool::ImplicitCollection::ImplicitCollection | ( | ISession * | session, |
const std::string & | connection, | ||
const std::string & | name, | ||
ICollection::OpenMode | mode | ||
) |
Constructor - old style Throws POOL exception.
session | the session object |
connection | database connection string. It has the format databaseNameType:databaseName, where databaseNameType can be FID, PFN or LFN. |
name | the container name in the database |
mode | collection's open mode. For the moment only READONLY mode is allowed. |
pool::ImplicitCollection::ImplicitCollection | ( | const ICollectionDescription * | description, |
ICollection::OpenMode | mode, | ||
ISession * | session | ||
) |
Constructor compying to the new Collections API parameters as above, but name and connection passed in description.
pool::ImplicitCollection::~ImplicitCollection | ( | ) |
Destructor.
|
delete |
|
virtual |
no-op at the moment
Implements pool::ICollection.
|
virtual |
Commits the last changes made to the collection. Will always return true.
Implements pool::ICollection.
|
virtual |
Returns an object used to add, update or delete rows of the collection.
will throw exception if called
Implements pool::ICollection.
|
virtual |
Returns an object used to describe the collection properties.
Implements pool::ICollection.
|
virtual |
Checks if the collection is open.
Implements pool::ICollection.
|
virtual |
Returns an object used to query the collection.
Implements pool::ICollection.
|
virtual |
no-op at the moment
Implements pool::ICollection.
|
protected |
|
virtual |
Return openMode.
Implements pool::ICollection.
|
delete |
void pool::ImplicitCollection::rollback | ( | ) |
Aborts the last changes made to the collection. Will always return true.
|
virtual |
Returns an object used to modify the collection schema.
will throw exception if called
Implements pool::ICollection.
ImplicitCollectionIterator* pool::ImplicitCollection::select | ( | const std::string & | primaryQuery = "" , |
std::string | secondaryQuery = "" , |
||
std::string | options = "" |
||
) |
Method that returns collection's iterator Throws POOL exception.
primaryQuery | query string passed to the underlying StorageSvc implementation. |
secondaryQuery | parameter currently unused |
options | type currently unused |
|
private |
The underlying container handle.
Definition at line 107 of file ImplicitCollection.h.
|
private |
Definition at line 109 of file ImplicitCollection.h.