Home Libraries Author Links

stm::tools::CtOperation Class Reference
[CtAids: ClearCase cleartool Aids]

List of all members.


Detailed Description

ClearCase cleartool operation class.

Definition at line 197 of file ctaids.hpp.


Public Member Functions

 CtOperation (Ct &ct, unsigned int getMastershipTimeoutSec=DefaultGetMastershipTimeoutSec)
 Constructs a CtOperation object for ct with get mastership timeout.
const Ctct () const
 Returns a constant reference to the Ct object of this CtOperation.
void setVobRoot (const std::string &vobRoot)
 Sets the ClearCase VOB root of this CtOperation to vobRoot.
const std::string & getVobRoot () const
 Returns the ClearCase VOB root of this CtOperation.
const std::string & getCurrentReplica () const
 Returns the current replica of the ClearCase VOB root of this CtOperation.
bool obtainReplicaMastership (const std::string &path) const
 Returns true, if the replica mastership for the ClearCase VOB element path could be obtained within getMastershipTimeout() seconds, else false.
void checkOut (const std::string &path) const
 The method checks out the ClearCase VOB element path.
bool isLabel (const std::string &label) const
 The method isLabel returns true, if label is defined as a ClearCase label, else false.

Static Public Attributes

static const unsigned int DefaultGetMastershipTimeoutSec = 5
 Default timeout in seconds to obtain the masterschip of a directory.

Constructor & Destructor Documentation

stm::tools::CtOperation::CtOperation ( Ct ct,
unsigned int  getMastershipTimeoutSec = DefaultGetMastershipTimeoutSec 
)

Constructs a CtOperation object for ct with get mastership timeout.


Member Function Documentation

const Ct& stm::tools::CtOperation::ct (  )  const

Returns a constant reference to the Ct object of this CtOperation.

void stm::tools::CtOperation::setVobRoot ( const std::string &  vobRoot  ) 

Sets the ClearCase VOB root of this CtOperation to vobRoot.

const std::string& stm::tools::CtOperation::getVobRoot (  )  const

Returns the ClearCase VOB root of this CtOperation.

const std::string& stm::tools::CtOperation::getCurrentReplica (  )  const

Returns the current replica of the ClearCase VOB root of this CtOperation.

bool stm::tools::CtOperation::obtainReplicaMastership ( const std::string &  path  )  const

Returns true, if the replica mastership for the ClearCase VOB element path could be obtained within getMastershipTimeout() seconds, else false.

void stm::tools::CtOperation::checkOut ( const std::string &  path  )  const

The method checks out the ClearCase VOB element path.

If path is a directory, first the replica masterschip is tried to obtain. On error a std::runtime_error exception is thrown.

bool stm::tools::CtOperation::isLabel ( const std::string &  label  )  const

The method isLabel returns true, if label is defined as a ClearCase label, else false.

Throws on error.


Member Data Documentation

const unsigned int stm::tools::CtOperation::DefaultGetMastershipTimeoutSec = 5 [static]

Default timeout in seconds to obtain the masterschip of a directory.

Definition at line 201 of file ctaids.hpp.


© Copyright Tom Michaelis 2002-2007

Distributed under the SysToMath Software License (See the accompanying file license.txt or a copy at www.SysToMath.com).