XRootD
XrdCl::RecorderFactory Class Reference

XrdCl recorder plug-in factory. More...

#include <XrdClRecorderPlugin.hh>

+ Inheritance diagram for XrdCl::RecorderFactory:
+ Collaboration diagram for XrdCl::RecorderFactory:

Public Member Functions

 RecorderFactory (const std::map< std::string, std::string > *config)
 
virtual ~RecorderFactory ()
 Destructor. More...
 
virtual FilePlugInCreateFile (const std::string &url)
 Create a file plug-in for the given URL. More...
 
virtual FileSystemPlugInCreateFileSystem (const std::string &url)
 Create a file system plug-in for the given URL. More...
 
- Public Member Functions inherited from XrdCl::PlugInFactory
virtual ~PlugInFactory ()
 Destructor. More...
 

Detailed Description

XrdCl recorder plug-in factory.

Definition at line 34 of file XrdClRecorderPlugin.hh.

Constructor & Destructor Documentation

◆ RecorderFactory()

XrdCl::RecorderFactory::RecorderFactory ( const std::map< std::string, std::string > *  config)
inline

Constructor

Parameters
configmap containing configuration parameters

Definition at line 42 of file XrdClRecorderPlugin.hh.

43  {
44  if( config )
45  {
46  auto itr = config->find( "output" );
47  Recorder::SetOutput( itr != config->end() ? itr->second : "" );
48  }
49  }
static void SetOutput(const std::string &cfgpath)

References XrdCl::Recorder::SetOutput().

+ Here is the call graph for this function:

◆ ~RecorderFactory()

virtual XrdCl::RecorderFactory::~RecorderFactory ( )
inlinevirtual

Destructor.

Definition at line 54 of file XrdClRecorderPlugin.hh.

55  {
56  }

Member Function Documentation

◆ CreateFile()

virtual FilePlugIn* XrdCl::RecorderFactory::CreateFile ( const std::string &  url)
inlinevirtual

Create a file plug-in for the given URL.

Implements XrdCl::PlugInFactory.

Definition at line 61 of file XrdClRecorderPlugin.hh.

62  {
63  std::unique_ptr<Recorder> ptr( new Recorder() );
64  if( !ptr->IsValid() )
65  return nullptr;
66  return static_cast<FilePlugIn*>( ptr.release() );
67  }

◆ CreateFileSystem()

virtual FileSystemPlugIn* XrdCl::RecorderFactory::CreateFileSystem ( const std::string &  url)
inlinevirtual

Create a file system plug-in for the given URL.

Implements XrdCl::PlugInFactory.

Definition at line 72 of file XrdClRecorderPlugin.hh.

73  {
74  Log* log = DefaultEnv::GetLog();
75  log->Error(1, "FileSystem plugin implementation not supported");
76  return static_cast<FileSystemPlugIn*>(0);
77  }
static Log * GetLog()
Get default log.
XrdSysError Log
Definition: XrdConfig.cc:112

References XrdCl::Log::Error(), and XrdCl::DefaultEnv::GetLog().

+ Here is the call graph for this function:

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