CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Static Public Member Functions | Private Attributes
ora::PoolDatabaseSchema Class Reference

#include <PoolDatabaseSchema.h>

Inheritance diagram for ora::PoolDatabaseSchema:
ora::IDatabaseSchema

Public Member Functions

IDatabaseTableclassVersionTable ()
 
IContainerHeaderTablecontainerHeaderTable ()
 
void create ()
 
void drop ()
 
bool exists ()
 
IMainTablemainTable ()
 
IDatabaseTablemappingElementTable ()
 
IMappingSchemamappingSchema ()
 
IDatabaseTablemappingVersionTable ()
 
INamingServiceTablenamingServiceTable ()
 
 PoolDatabaseSchema (coral::ISchema &dbSchema)
 
ISequenceTablesequenceTable ()
 
virtual ~PoolDatabaseSchema ()
 
- Public Member Functions inherited from ora::IDatabaseSchema
 IDatabaseSchema (coral::ISchema &schema)
 
coral::ISchema & storageSchema ()
 
virtual ~IDatabaseSchema ()
 

Static Public Member Functions

static bool existsMainTable (coral::ISchema &dbSchema)
 
- Static Public Member Functions inherited from ora::IDatabaseSchema
static IDatabaseSchemacreateSchemaHandle (coral::ISchema &schema)
 

Private Attributes

PoolClassVersionTable m_classVersionTable
 
PoolContainerHeaderTable m_containerHeaderTable
 
PoolDbCache m_dbCache
 
PoolMainTable m_mainTable
 
PoolMappingElementTable m_mappingElementTable
 
PoolMappingSchema m_mappingSchema
 
PoolMappingVersionTable m_mappingVersionTable
 
CondMetadataTable m_metadataTable
 
coral::ISchema & m_schema
 
PoolSequenceTable m_sequenceTable
 

Detailed Description

Definition at line 227 of file PoolDatabaseSchema.h.

Constructor & Destructor Documentation

ora::PoolDatabaseSchema::PoolDatabaseSchema ( coral::ISchema &  dbSchema)
explicit

Definition at line 1273 of file PoolDatabaseSchema.cc.

References ora::PoolSequenceTable::init(), ora::PoolContainerHeaderTable::init(), ora::PoolMappingSchema::init(), m_containerHeaderTable, m_dbCache, m_mappingSchema, and m_sequenceTable.

1273  :
1274  IDatabaseSchema( dbSchema ),
1275  m_schema( dbSchema ),
1276  m_dbCache(),
1277  m_mainTable( dbSchema ),
1278  m_sequenceTable( dbSchema ),
1279  m_mappingVersionTable( dbSchema ),
1280  m_mappingElementTable( dbSchema ),
1281  m_containerHeaderTable( dbSchema ),
1282  m_classVersionTable( dbSchema ),
1283  m_mappingSchema( dbSchema ),
1284  m_metadataTable( dbSchema, m_dbCache ){
1288 }
void init(PoolDbCache &dbCache)
PoolMappingSchema m_mappingSchema
PoolClassVersionTable m_classVersionTable
void init(PoolDbCache &dbCache)
PoolMappingElementTable m_mappingElementTable
PoolSequenceTable m_sequenceTable
CondMetadataTable m_metadataTable
IDatabaseSchema(coral::ISchema &schema)
void init(PoolDbCache &dbCache)
PoolMappingVersionTable m_mappingVersionTable
PoolContainerHeaderTable m_containerHeaderTable
ora::PoolDatabaseSchema::~PoolDatabaseSchema ( )
virtual

Definition at line 1290 of file PoolDatabaseSchema.cc.

1290  {
1291 }

Member Function Documentation

ora::IDatabaseTable & ora::PoolDatabaseSchema::classVersionTable ( )
virtual

Implements ora::IDatabaseSchema.

Definition at line 1346 of file PoolDatabaseSchema.cc.

1346  {
1347  return m_classVersionTable;
1348 }
PoolClassVersionTable m_classVersionTable
ora::IContainerHeaderTable & ora::PoolDatabaseSchema::containerHeaderTable ( )
virtual

Implements ora::IDatabaseSchema.

Definition at line 1342 of file PoolDatabaseSchema.cc.

1342  {
1343  return m_containerHeaderTable;
1344 }
PoolContainerHeaderTable m_containerHeaderTable
void ora::PoolDatabaseSchema::create ( )
virtual

Implements ora::IDatabaseSchema.

Definition at line 1313 of file PoolDatabaseSchema.cc.

References ora::throwException().

1313  {
1314  throwException( "POOL database cannot be created.","PoolDatabaseSchema::create");
1315 }
void throwException(const std::string &message, const std::string &methodName)
Definition: Exception.cc:10
void ora::PoolDatabaseSchema::drop ( )
virtual

Implements ora::IDatabaseSchema.

Definition at line 1317 of file PoolDatabaseSchema.cc.

bool ora::PoolDatabaseSchema::exists ( )
virtual

Implements ora::IDatabaseSchema.

Definition at line 1293 of file PoolDatabaseSchema.cc.

References ora::throwException().

1293  {
1294  if(!m_mainTable.exists()){
1295  return false;
1296  }
1297 
1298  if(!m_sequenceTable.exists() ||
1303  throwException( "POOL database is corrupted..",
1304  "PoolDatabaseSchema::exists");
1305  }
1306  if( !m_metadataTable.exists()){
1307  throwException( "Metadata table has not been found.",
1308  "PoolDatabaseSchema::exists");
1309  }
1310  return true;
1311 }
PoolClassVersionTable m_classVersionTable
PoolMappingElementTable m_mappingElementTable
PoolSequenceTable m_sequenceTable
CondMetadataTable m_metadataTable
PoolMappingVersionTable m_mappingVersionTable
PoolContainerHeaderTable m_containerHeaderTable
void throwException(const std::string &message, const std::string &methodName)
Definition: Exception.cc:10
bool ora::PoolDatabaseSchema::existsMainTable ( coral::ISchema &  dbSchema)
static

Definition at line 1268 of file PoolDatabaseSchema.cc.

References ora::PoolMainTable::exists(), and tmp.

Referenced by ora::IDatabaseSchema::createSchemaHandle().

1268  {
1269  PoolMainTable tmp( dbSchema );
1270  return tmp.exists();
1271 }
std::vector< std::vector< double > > tmp
Definition: MVATrainer.cc:100
ora::IMainTable & ora::PoolDatabaseSchema::mainTable ( )
virtual

Implements ora::IDatabaseSchema.

Definition at line 1326 of file PoolDatabaseSchema.cc.

1326  {
1327  return m_mainTable;
1328 }
ora::IDatabaseTable & ora::PoolDatabaseSchema::mappingElementTable ( )
virtual

Implements ora::IDatabaseSchema.

Definition at line 1338 of file PoolDatabaseSchema.cc.

1338  {
1339  return m_mappingElementTable;
1340 }
PoolMappingElementTable m_mappingElementTable
ora::IMappingSchema & ora::PoolDatabaseSchema::mappingSchema ( )
virtual

Implements ora::IDatabaseSchema.

Definition at line 1350 of file PoolDatabaseSchema.cc.

1350  {
1351  return m_mappingSchema;
1352 }
PoolMappingSchema m_mappingSchema
ora::IDatabaseTable & ora::PoolDatabaseSchema::mappingVersionTable ( )
virtual

Implements ora::IDatabaseSchema.

Definition at line 1334 of file PoolDatabaseSchema.cc.

1334  {
1335  return m_mappingVersionTable;
1336 }
PoolMappingVersionTable m_mappingVersionTable
ora::INamingServiceTable & ora::PoolDatabaseSchema::namingServiceTable ( )
virtual

Implements ora::IDatabaseSchema.

Definition at line 1354 of file PoolDatabaseSchema.cc.

1354  {
1355  return m_metadataTable;
1356 }
CondMetadataTable m_metadataTable
ora::ISequenceTable & ora::PoolDatabaseSchema::sequenceTable ( )
virtual

Implements ora::IDatabaseSchema.

Definition at line 1330 of file PoolDatabaseSchema.cc.

1330  {
1331  return m_sequenceTable;
1332 }
PoolSequenceTable m_sequenceTable

Member Data Documentation

PoolClassVersionTable ora::PoolDatabaseSchema::m_classVersionTable
private

Definition at line 255 of file PoolDatabaseSchema.h.

PoolContainerHeaderTable ora::PoolDatabaseSchema::m_containerHeaderTable
private

Definition at line 254 of file PoolDatabaseSchema.h.

Referenced by PoolDatabaseSchema().

PoolDbCache ora::PoolDatabaseSchema::m_dbCache
private

Definition at line 249 of file PoolDatabaseSchema.h.

Referenced by PoolDatabaseSchema().

PoolMainTable ora::PoolDatabaseSchema::m_mainTable
private

Definition at line 250 of file PoolDatabaseSchema.h.

PoolMappingElementTable ora::PoolDatabaseSchema::m_mappingElementTable
private

Definition at line 253 of file PoolDatabaseSchema.h.

PoolMappingSchema ora::PoolDatabaseSchema::m_mappingSchema
private

Definition at line 256 of file PoolDatabaseSchema.h.

Referenced by PoolDatabaseSchema().

PoolMappingVersionTable ora::PoolDatabaseSchema::m_mappingVersionTable
private

Definition at line 252 of file PoolDatabaseSchema.h.

CondMetadataTable ora::PoolDatabaseSchema::m_metadataTable
private

Definition at line 257 of file PoolDatabaseSchema.h.

coral::ISchema& ora::PoolDatabaseSchema::m_schema
private

Definition at line 248 of file PoolDatabaseSchema.h.

PoolSequenceTable ora::PoolDatabaseSchema::m_sequenceTable
private

Definition at line 251 of file PoolDatabaseSchema.h.

Referenced by PoolDatabaseSchema().