CMS 3D CMS Logo

Public Member Functions | Static Public Member Functions | Private Attributes

ora::PoolMappingVersionTable Class Reference

#include <PoolDatabaseSchema.h>

Inheritance diagram for ora::PoolMappingVersionTable:
ora::IDatabaseTable

List of all members.

Public Member Functions

void create ()
void drop ()
bool exists ()
 PoolMappingVersionTable (coral::ISchema &dbSchema)
virtual ~PoolMappingVersionTable ()

Static Public Member Functions

static std::string containerNameColumn ()
static std::string mappingVersionColumn ()
static std::string tableName ()

Private Attributes

coral::ISchema & m_schema

Detailed Description

Definition at line 87 of file PoolDatabaseSchema.h.


Constructor & Destructor Documentation

ora::PoolMappingVersionTable::PoolMappingVersionTable ( coral::ISchema &  dbSchema) [explicit]

Definition at line 203 of file PoolDatabaseSchema.cc.

                                                                            :
  m_schema( dbSchema ){
}
ora::PoolMappingVersionTable::~PoolMappingVersionTable ( ) [virtual]

Definition at line 207 of file PoolDatabaseSchema.cc.

                                                    {
}

Member Function Documentation

std::string ora::PoolMappingVersionTable::containerNameColumn ( ) [static]

Definition at line 198 of file PoolDatabaseSchema.cc.

                                                         {
  static std::string s_col("CONTAINER_ID");
  return s_col;
}
void ora::PoolMappingVersionTable::create ( ) [virtual]

Implements ora::IDatabaseTable.

Definition at line 214 of file PoolDatabaseSchema.cc.

References ora::throwException().

                                       {
  if( m_schema.existsTable( tableName() )){
    throwException( "POOL database mapping version table already exists in this schema.",
                    "PoolMappingVersionTable::create");
  }
  throwException( "POOL database cannot be created.","PoolMappingVersionTable::create");  
}
void ora::PoolMappingVersionTable::drop ( ) [virtual]

Implements ora::IDatabaseTable.

Definition at line 222 of file PoolDatabaseSchema.cc.

                                     {
  m_schema.dropIfExistsTable( tableName() );
}
bool ora::PoolMappingVersionTable::exists ( ) [virtual]

Implements ora::IDatabaseTable.

Definition at line 210 of file PoolDatabaseSchema.cc.

                                       {
  return m_schema.existsTable( tableName() );
}
std::string ora::PoolMappingVersionTable::mappingVersionColumn ( ) [static]

Definition at line 193 of file PoolDatabaseSchema.cc.

Referenced by ora::PoolMappingSchema::getVersionList(), ora::PoolMappingSchema::removeMapping(), and ora::PoolMappingSchema::storeMapping().

                                                          {
  static std::string s_col("MAPPING_VERSION");
  return s_col;
}
std::string ora::PoolMappingVersionTable::tableName ( ) [static]

Definition at line 188 of file PoolDatabaseSchema.cc.

Referenced by ora::PoolMappingSchema::getVersionList(), ora::PoolMappingSchema::removeMapping(), and ora::PoolMappingSchema::storeMapping().

                                               {
  static std::string s_table("POOL_OR_MAPPING_VERSIONS");
  return s_table;
}

Member Data Documentation

coral::ISchema& ora::PoolMappingVersionTable::m_schema [private]

Definition at line 100 of file PoolDatabaseSchema.h.