ATLAS Offline Software
Public Member Functions | Private Attributes | List of all members
H5FileSvc Class Reference

#include <H5FileSvc.h>

Inheritance diagram for H5FileSvc:
Collaboration diagram for H5FileSvc:

Public Member Functions

 H5FileSvc (const std::string &name, ISvcLocator *pSvcLocator)
 
 ~H5FileSvc ()
 
virtual StatusCode initialize () override
 
virtual H5::Group * group () override
 

Private Attributes

std::unique_ptr< H5::H5File > m_file {nullptr}
 
Gaudi::Property< std::string > m_file_path {this, "path", "", "path to file"}
 

Detailed Description

Definition at line 18 of file H5FileSvc.h.

Constructor & Destructor Documentation

◆ H5FileSvc()

H5FileSvc::H5FileSvc ( const std::string &  name,
ISvcLocator *  pSvcLocator 
)

Definition at line 7 of file H5FileSvc.cxx.

7  :
8  base_class(name, pSvcLocator)
9 {
10 }

◆ ~H5FileSvc()

H5FileSvc::~H5FileSvc ( )
default

Member Function Documentation

◆ group()

H5::Group * H5FileSvc::group ( )
overridevirtual

Definition at line 22 of file H5FileSvc.cxx.

22  {
23  return m_file.get();
24 }

◆ initialize()

StatusCode H5FileSvc::initialize ( )
overridevirtual

Definition at line 14 of file H5FileSvc.cxx.

14  {
15  if (m_file_path.empty()) {
16  return StatusCode::FAILURE;
17  }
18  m_file = std::make_unique<H5::H5File>(m_file_path, H5F_ACC_TRUNC);
19  return StatusCode::SUCCESS;
20 }

Member Data Documentation

◆ m_file

std::unique_ptr<H5::H5File> H5FileSvc::m_file {nullptr}
private

Definition at line 27 of file H5FileSvc.h.

◆ m_file_path

Gaudi::Property<std::string> H5FileSvc::m_file_path {this, "path", "", "path to file"}
private

Definition at line 28 of file H5FileSvc.h.


The documentation for this class was generated from the following files:
H5FileSvc::m_file_path
Gaudi::Property< std::string > m_file_path
Definition: H5FileSvc.h:28
H5FileSvc::m_file
std::unique_ptr< H5::H5File > m_file
Definition: H5FileSvc.h:27
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221