ATLAS Offline Software
Loading...
Searching...
No Matches
ExtractFileIdentifierApplication Class Reference
Inheritance diagram for ExtractFileIdentifierApplication:
Collaboration diagram for ExtractFileIdentifierApplication:

Public Member Functions

 ExtractFileIdentifierApplication (int argc, char *argv[])
bool parseArguments ()
void execute ()
void printSyntax ()
virtual int run ()
virtual void startSession ATLAS_NOT_THREAD_SAFE ()
virtual void readFileGUIDs ()
virtual std::string readFileGUID (const std::string &pfn)

Static Public Member Functions

static bool initGaudi ()
 initialize the Gaudi framework for standalone executables

Protected Attributes

std::string executableName
std::string technologyName
pool::IStorageSvcstorageSvc = nullptr
std::vector< std::string > args
std::vector< std::string > fileNames
std::vector< std::pair< std::string, std::string > > fidAndPfn

Detailed Description

Definition at line 13 of file pool_extractFileIdentifier.cxx.

Constructor & Destructor Documentation

◆ ExtractFileIdentifierApplication()

ExtractFileIdentifierApplication::ExtractFileIdentifierApplication ( int argc,
char * argv[] )

Definition at line 23 of file pool_extractFileIdentifier.cxx.

24 : SimpleUtilityBase( argc, argv )
25{ }
SimpleUtilityBase(int argc=0, char *argv[]=0)
constructor taking commandline parmeters

Member Function Documentation

◆ ATLAS_NOT_THREAD_SAFE()

virtual void startSession pool::SimpleUtilityBase::ATLAS_NOT_THREAD_SAFE ( )
virtualinherited

◆ execute()

void ExtractFileIdentifierApplication::execute ( )
virtual

Reimplemented from pool::SimpleUtilityBase.

Definition at line 53 of file pool_extractFileIdentifier.cxx.

54{
55 startSession();
57 for( std::vector< std::pair< std::string, std::string > >::const_iterator iFile = fidAndPfn.begin();
58 iFile != fidAndPfn.end(); ++iFile ) {
59 std::cout << iFile->first << " (" << iFile->second << ")" << std::endl;
60 }
61}
virtual void readFileGUIDs()
std::vector< std::pair< std::string, std::string > > fidAndPfn

◆ initGaudi()

bool pool::SimpleUtilityBase::initGaudi ( )
staticinherited

initialize the Gaudi framework for standalone executables

◆ parseArguments()

bool ExtractFileIdentifierApplication::parseArguments ( )
virtual

Reimplemented from pool::SimpleUtilityBase.

Definition at line 29 of file pool_extractFileIdentifier.cxx.

30{
31 unsigned int excludedArgument = 0;
32 for ( unsigned int iArg = 0; iArg < args.size(); ++iArg ) {
33 if ( iArg > 0 && iArg == excludedArgument )
34 continue;
35 const std::string& arg = args[iArg];
36 if ( arg == "-t" ) {
37 unsigned int nextArgumentIndex = iArg + 1;
38 if ( nextArgumentIndex < args.size() ) {
39 excludedArgument = nextArgumentIndex;
40 technologyName = args[nextArgumentIndex];
41 }
42 }
43 else {
44 fileNames.push_back( arg );
45 }
46 }
48}
std::vector< std::string > fileNames
std::vector< std::string > args
virtual bool parseArguments()

◆ printSyntax()

void ExtractFileIdentifierApplication::printSyntax ( )
virtual

Reimplemented from pool::SimpleUtilityBase.

Definition at line 65 of file pool_extractFileIdentifier.cxx.

66{
67 std::cerr << "Syntax : " << executableName << " [-t technologyType] files" << std::endl;
68}

◆ readFileGUID()

virtual std::string pool::SimpleUtilityBase::readFileGUID ( const std::string & pfn)
virtualinherited

◆ readFileGUIDs()

virtual void pool::SimpleUtilityBase::readFileGUIDs ( )
virtualinherited

◆ run()

virtual int pool::SimpleUtilityBase::run ( )
virtualinherited

Member Data Documentation

◆ args

std::vector< std::string > pool::SimpleUtilityBase::args
protectedinherited

Definition at line 47 of file SimpleUtilityBase.h.

◆ executableName

std::string pool::SimpleUtilityBase::executableName
protectedinherited

Definition at line 43 of file SimpleUtilityBase.h.

◆ fidAndPfn

std::vector< std::pair< std::string, std::string > > pool::SimpleUtilityBase::fidAndPfn
protectedinherited

Definition at line 49 of file SimpleUtilityBase.h.

◆ fileNames

std::vector< std::string > pool::SimpleUtilityBase::fileNames
protectedinherited

Definition at line 48 of file SimpleUtilityBase.h.

◆ storageSvc

pool::IStorageSvc* pool::SimpleUtilityBase::storageSvc = nullptr
protectedinherited

Definition at line 45 of file SimpleUtilityBase.h.

◆ technologyName

std::string pool::SimpleUtilityBase::technologyName
protectedinherited

Definition at line 44 of file SimpleUtilityBase.h.


The documentation for this class was generated from the following file: