ATLAS Offline Software
Loading...
Searching...
No Matches
SimpleUtilityBase.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef POOL_SIMPLEUTILITYBASE
6#define POOL_SIMPLEUTILITYBASE
7
8#include <iostream>
9#include <stdexcept>
10#include <vector>
11
13#include "StorageSvc/DbType.h"
14#include "StorageSvc/DbOption.h"
16
18
19namespace pool {
20
23 {
24 public:
26 SimpleUtilityBase( int argc = 0, char* argv[] = 0 );
28
29 virtual int run();
30
31 virtual bool parseArguments();
32 virtual void startSession ATLAS_NOT_THREAD_SAFE ();
33 virtual void readFileGUIDs();
34 virtual std::string readFileGUID( const std::string& pfn );
35
36 virtual void execute() {}
37 virtual void printSyntax() {}
38
39 protected:
40 std::string executableName;
41 std::string technologyName;
42
43 pool::Session* session = nullptr;
45
46 std::vector< std::string > args;
47 std::vector< std::string > fileNames;
48 std::vector< std::pair< std::string, std::string > > fidAndPfn;
49 };
50
51
53 /* this is a class and not a namespace so it can be autoloaded by ROOT */
54 class Utils {
55 public:
56 static std::string readFileGUID ATLAS_NOT_THREAD_SAFE ( const std::string& pfn );
57 };
58
59
60} // pool namespace
61#endif
Define macros for attributes used to control the static checker.
The IStorageSvc interface is able to handle user request for.
Definition IStorageSvc.h:56
std::vector< std::string > fileNames
virtual void startSession ATLAS_NOT_THREAD_SAFE()
pool::IStorageSvc * storageSvc
std::vector< std::string > args
virtual void readFileGUIDs()
virtual std::string readFileGUID(const std::string &pfn)
SimpleUtilityBase(int argc=0, char *argv[]=0)
constructor taking commandline parmeters
virtual bool parseArguments()
std::vector< std::pair< std::string, std::string > > fidAndPfn
static std::string readFileGUID ATLAS_NOT_THREAD_SAFE(const std::string &pfn)
pool namespace
Definition libname.h:15