CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Attributes
ora::RelationalPtrLoader Class Reference
Inheritance diagram for ora::RelationalPtrLoader:
ora::IPtrLoader

Public Member Functions

void invalidate () override
 
bool isValid () const override
 
void * load () const override
 
 RelationalPtrLoader (OraPtrReadBuffer &buffer, const std::vector< int > &fullId)
 
virtual ~RelationalPtrLoader ()
 
- Public Member Functions inherited from ora::IPtrLoader
virtual ~IPtrLoader ()
 

Private Attributes

OraPtrReadBufferm_buffer
 
std::vector< int > m_fullId
 
bool m_valid
 

Detailed Description

Definition at line 107 of file OraPtrStreamer.cc.

Constructor & Destructor Documentation

ora::RelationalPtrLoader::RelationalPtrLoader ( OraPtrReadBuffer buffer,
const std::vector< int > &  fullId 
)
inline

Definition at line 109 of file OraPtrStreamer.cc.

109  :
110  m_buffer( buffer ),
111  m_fullId( fullId ),
112  m_valid( true ){
113  }
OraPtrReadBuffer & m_buffer
std::vector< int > m_fullId
virtual ora::RelationalPtrLoader::~RelationalPtrLoader ( )
inlinevirtual

Definition at line 115 of file OraPtrStreamer.cc.

115  {
116  }

Member Function Documentation

void ora::RelationalPtrLoader::invalidate ( )
inlineoverridevirtual

Implements ora::IPtrLoader.

Definition at line 127 of file OraPtrStreamer.cc.

References m_valid.

127  {
128  m_valid = false;
129  }
bool ora::RelationalPtrLoader::isValid ( void  ) const
inlineoverridevirtual

Implements ora::IPtrLoader.

Definition at line 131 of file OraPtrStreamer.cc.

References m_valid.

Referenced by core.AutoHandle.AutoHandle::ReallyLoad().

131  {
132  return m_valid;
133  }
void* ora::RelationalPtrLoader::load ( ) const
inlineoverridevirtual

Implements ora::IPtrLoader.

Definition at line 119 of file OraPtrStreamer.cc.

References m_buffer, m_fullId, m_valid, ora::OraPtrReadBuffer::read(), and ora::throwException().

Referenced by MatrixToProcess.MatrixToProcess::getProcess(), and MatrixToProcess.MatrixToProcess::listAll().

119  {
120  if(!m_valid){
121  throwException("Ptr Loader has been invalidate.",
122  "RelationalPtrLoader::load");
123  }
124  return m_buffer.read( m_fullId );
125  }
void * read(const std::vector< int > &fullId)
OraPtrReadBuffer & m_buffer
std::vector< int > m_fullId
void throwException(const std::string &message, const std::string &methodName) __attribute__((noreturn))
Definition: Exception.cc:10

Member Data Documentation

OraPtrReadBuffer& ora::RelationalPtrLoader::m_buffer
private

Definition at line 136 of file OraPtrStreamer.cc.

Referenced by load().

std::vector<int> ora::RelationalPtrLoader::m_fullId
private

Definition at line 137 of file OraPtrStreamer.cc.

Referenced by load().

bool ora::RelationalPtrLoader::m_valid
private

Definition at line 138 of file OraPtrStreamer.cc.

Referenced by invalidate(), isValid(), and load().