The Gaudi Framework  master (0acd68ed)
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
Gaudi::IFileCatalog Class Referenceabstract

#include <GaudiUtils/IFileCatalog.h>

Inheritance diagram for Gaudi::IFileCatalog:
Collaboration diagram for Gaudi::IFileCatalog:

Public Types

using Factory = Gaudi::PluginService::Factory< IInterface *(const std::string &, IMessageSvc *)>
 
typedef std::pair< std::string, std::string > NamedItem
 Public type definitions. More...
 
typedef std::vector< NamedItemAttributes
 
typedef std::vector< NamedItemFiles
 
typedef std::vector< std::string > Strings
 
- Public Types inherited from IInterface
enum  Status : StatusCode::code_t {
  Status::FAILURE = 0, Status::SUCCESS = 1, Status::NO_INTERFACE, Status::VERSMISMATCH,
  Status::LAST_ERROR
}
 Return status. More...
 
using iid = Gaudi::InterfaceId< IInterface, 0, 0 >
 Interface ID. More...
 
using ext_iids = Gaudi::interface_list< iid >
 Extra interfaces. More...
 

Public Member Functions

 DeclareInterfaceID (IFileCatalog, 2, 0)
 InterfaceID. More...
 
virtual std::string createFID () const =0
 Catalog interface
More...
 
virtual const std::string & connectInfo () const =0
 Access to connect string. More...
 
virtual void init ()=0
 Parse the DOM tree of the XML catalog. More...
 
virtual void commit ()=0
 Save catalog to file. More...
 
virtual void rollback ()=0
 Save catalog to file. More...
 
virtual bool readOnly () const =0
 Check if the catalog is read-only. More...
 
virtual bool dirty () const =0
 Check if the catalog should be updated. More...
 
virtual void getPFN (const std::string &fid, Files &files) const =0
 Dump all PFNames of the catalog and their attributes associate to the FileID. More...
 
virtual void getLFN (const std::string &fid, Files &files) const =0
 Dump all LFNames of the catalog associate to the FileID. More...
 
virtual void getFID (Strings &fids) const =0
 Dump all file Identifiers. More...
 
virtual bool existsPFN (const std::string &pfn) const =0
 Return the status of a PFName. More...
 
virtual std::string lookupPFN (const std::string &lfn) const =0
 Lookup file identifier by physical file name. More...
 
virtual bool existsLFN (const std::string &lfn) const =0
 Return the status of a LFName. More...
 
virtual std::string lookupLFN (const std::string &lfn) const =0
 Lookup file identifier by physical file name. More...
 
virtual bool existsFID (const std::string &fid) const =0
 Return the status of a FileID. More...
 
virtual void deleteFID (const std::string &FileID) const =0
 Delete FileID Node from the catalog. More...
 
virtual void registerPFN (const std::string &fid, const std::string &pfn, const std::string &ftype) const =0
 Create a Node for a FileID and DOM Node of the PFN with all the attributes. More...
 
virtual void registerLFN (const std::string &fid, const std::string &lfn) const =0
 Create a Node for a FileID and DOM Node of the LFN with all the attributes. More...
 
virtual void registerFID (const std::string &fid) const =0
 Create a Node for a FileID and DOM Node. More...
 
virtual void renamePFN (const std::string &pfn, const std::string &new_pfn) const =0
 rename a PFN More...
 
virtual void deletePFN (const std::string &pfn) const =0
 remove a PFN More...
 
virtual void getMetaData (const std::string &fid, Attributes &attr) const =0
 Dump all MetaData of the catalog for a given file ID. More...
 
virtual std::string getMetaDataItem (const std::string &fid, const std::string &name) const =0
 Access metadata item. More...
 
virtual void setMetaData (const std::string &fid, const std::string &name, const std::string &value) const =0
 Insert/update metadata item. More...
 
virtual void dropMetaData (const std::string &fid) const =0
 Drop all metadata of one FID. More...
 
virtual void dropMetaData (const std::string &fid, const std::string &attr) const =0
 Drop specified metadata item. More...
 
- Public Member Functions inherited from IInterface
template<Gaudi::IsInterface TARGET>
TARGET * cast ()
 
template<Gaudi::IsInterface TARGET>
TARGET const * cast () const
 
template<typename TARGET >
 requires (!Gaudi::IsInterface< TARGET >) TARGET *cast()
 
template<typename TARGET >
 requires (!Gaudi::IsInterface< TARGET >) TARGET const *cast() const
 
virtual std::vector< std::string > getInterfaceNames () const =0
 Returns a vector of strings containing the names of all the implemented interfaces. More...
 
virtual unsigned long addRef () const =0
 Increment the reference count of Interface instance. More...
 
virtual unsigned long release () const =0
 Release Interface instance. More...
 
virtual unsigned long refCount () const =0
 Current reference count. More...
 
virtual StatusCode queryInterface (const InterfaceID &ti, void **pp)=0
 Set the void** to the pointer to the requested interface of the instance. More...
 
virtual ~IInterface ()=default
 Virtual destructor. More...
 
virtual void const * i_cast (const InterfaceID &) const =0
 
void * i_cast (const InterfaceID &iid)
 

Additional Inherited Members

- Static Public Member Functions inherited from IInterface
static const InterfaceIDinterfaceID ()
 Return an instance of InterfaceID identifying the interface. More...
 
- Protected Member Functions inherited from IInterface
virtual unsigned long decRef () const =0
 Decrement reference count and return the new reference count. More...
 

Detailed Description

File catalog interface. Resolve file ids, physical and logical file names.

Author
M.Frank
Version
1.0
Date
20/10/2007

Definition at line 36 of file IFileCatalog.h.

Member Typedef Documentation

◆ Attributes

Definition at line 46 of file IFileCatalog.h.

◆ Factory

using Gaudi::IFileCatalog::Factory = Gaudi::PluginService::Factory<IInterface*( const std::string&, IMessageSvc* )>

Definition at line 42 of file IFileCatalog.h.

◆ Files

typedef std::vector<NamedItem> Gaudi::IFileCatalog::Files

Definition at line 47 of file IFileCatalog.h.

◆ NamedItem

typedef std::pair<std::string, std::string> Gaudi::IFileCatalog::NamedItem

Public type definitions.

Definition at line 45 of file IFileCatalog.h.

◆ Strings

typedef std::vector<std::string> Gaudi::IFileCatalog::Strings

Definition at line 48 of file IFileCatalog.h.

Member Function Documentation

◆ commit()

virtual void Gaudi::IFileCatalog::commit ( )
pure virtual

Save catalog to file.

◆ connectInfo()

virtual const std::string& Gaudi::IFileCatalog::connectInfo ( ) const
pure virtual

Access to connect string.

◆ createFID()

virtual std::string Gaudi::IFileCatalog::createFID ( ) const
pure virtual

Catalog interface

Create file identifier using UUID mechanism

◆ DeclareInterfaceID()

Gaudi::IFileCatalog::DeclareInterfaceID ( IFileCatalog  ,
,
 
)

◆ deleteFID()

virtual void Gaudi::IFileCatalog::deleteFID ( const std::string &  FileID) const
pure virtual

Delete FileID Node from the catalog.

◆ deletePFN()

virtual void Gaudi::IFileCatalog::deletePFN ( const std::string &  pfn) const
pure virtual

remove a PFN

◆ dirty()

virtual bool Gaudi::IFileCatalog::dirty ( ) const
pure virtual

Check if the catalog should be updated.

◆ dropMetaData() [1/2]

virtual void Gaudi::IFileCatalog::dropMetaData ( const std::string &  fid) const
pure virtual

Drop all metadata of one FID.

◆ dropMetaData() [2/2]

virtual void Gaudi::IFileCatalog::dropMetaData ( const std::string &  fid,
const std::string &  attr 
) const
pure virtual

Drop specified metadata item.

◆ existsFID()

virtual bool Gaudi::IFileCatalog::existsFID ( const std::string &  fid) const
pure virtual

Return the status of a FileID.

◆ existsLFN()

virtual bool Gaudi::IFileCatalog::existsLFN ( const std::string &  lfn) const
pure virtual

Return the status of a LFName.

◆ existsPFN()

virtual bool Gaudi::IFileCatalog::existsPFN ( const std::string &  pfn) const
pure virtual

Return the status of a PFName.

◆ getFID()

virtual void Gaudi::IFileCatalog::getFID ( Strings fids) const
pure virtual

Dump all file Identifiers.

◆ getLFN()

virtual void Gaudi::IFileCatalog::getLFN ( const std::string &  fid,
Files files 
) const
pure virtual

Dump all LFNames of the catalog associate to the FileID.

◆ getMetaData()

virtual void Gaudi::IFileCatalog::getMetaData ( const std::string &  fid,
Attributes attr 
) const
pure virtual

Dump all MetaData of the catalog for a given file ID.

◆ getMetaDataItem()

virtual std::string Gaudi::IFileCatalog::getMetaDataItem ( const std::string &  fid,
const std::string &  name 
) const
pure virtual

Access metadata item.

◆ getPFN()

virtual void Gaudi::IFileCatalog::getPFN ( const std::string &  fid,
Files files 
) const
pure virtual

Dump all PFNames of the catalog and their attributes associate to the FileID.

◆ init()

virtual void Gaudi::IFileCatalog::init ( )
pure virtual

Parse the DOM tree of the XML catalog.

◆ lookupLFN()

virtual std::string Gaudi::IFileCatalog::lookupLFN ( const std::string &  lfn) const
pure virtual

Lookup file identifier by physical file name.

◆ lookupPFN()

virtual std::string Gaudi::IFileCatalog::lookupPFN ( const std::string &  lfn) const
pure virtual

Lookup file identifier by physical file name.

◆ readOnly()

virtual bool Gaudi::IFileCatalog::readOnly ( ) const
pure virtual

Check if the catalog is read-only.

◆ registerFID()

virtual void Gaudi::IFileCatalog::registerFID ( const std::string &  fid) const
pure virtual

Create a Node for a FileID and DOM Node.

◆ registerLFN()

virtual void Gaudi::IFileCatalog::registerLFN ( const std::string &  fid,
const std::string &  lfn 
) const
pure virtual

Create a Node for a FileID and DOM Node of the LFN with all the attributes.

◆ registerPFN()

virtual void Gaudi::IFileCatalog::registerPFN ( const std::string &  fid,
const std::string &  pfn,
const std::string &  ftype 
) const
pure virtual

Create a Node for a FileID and DOM Node of the PFN with all the attributes.

◆ renamePFN()

virtual void Gaudi::IFileCatalog::renamePFN ( const std::string &  pfn,
const std::string &  new_pfn 
) const
pure virtual

rename a PFN

◆ rollback()

virtual void Gaudi::IFileCatalog::rollback ( )
pure virtual

Save catalog to file.

◆ setMetaData()

virtual void Gaudi::IFileCatalog::setMetaData ( const std::string &  fid,
const std::string &  name,
const std::string &  value 
) const
pure virtual

Insert/update metadata item.


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