artdaq_core  3.09.12
artdaq::ArtdaqFragmentNameHelper Class Reference

Default implementation of FragmentNameHelper. More...

#include <artdaq-core/Plugins/ArtdaqFragmentNameHelper.hh>

Inheritance diagram for artdaq::ArtdaqFragmentNameHelper:
artdaq::FragmentNameHelper

Public Member Functions

virtual ~ArtdaqFragmentNameHelper ()
 DefaultArtdaqFragmentNameHelper Destructor.
 
 ArtdaqFragmentNameHelper (std::string unidentified_instance_name, std::vector< std::pair< artdaq::Fragment::type_t, std::string >> extraTypes)
 ArtdaqFragmentNameHelper Constructor. More...
 
- Public Member Functions inherited from artdaq::FragmentNameHelper
virtual ~FragmentNameHelper ()=default
 Default virtual destructor.
 
 FragmentNameHelper (std::string unidentified_instance_name, std::vector< std::pair< artdaq::Fragment::type_t, std::string >> extraTypes)
 FragmentNameHelper Constructor. More...
 
void SetBasicTypes (std::map< artdaq::Fragment::type_t, std::string > const &type_map)
 Sets the basic types to be translated. (Should not include "container" types.)
 
void AddExtraType (artdaq::Fragment::type_t type_id, std::string const &type_name)
 Adds an additional type to be translated.
 
std::string GetUnidentifiedInstanceName () const
 Get the configured unidentified_instance_name. More...
 
virtual std::string GetInstanceNameForType (artdaq::Fragment::type_t type_id) const
 Returns the basic translation for the specified type. Must be implemented by derived classes.
 
virtual std::set< std::string > GetAllProductInstanceNames () const
 Returns the full set of product instance names which may be present in the data, based on the types that have been specified in the SetBasicTypes() and AddExtraType() methods. This does include "container" types, if the container type mapping is part of the basic types. Must be implemented by derived classes.
 
virtual std::pair< bool,
std::string > 
GetInstanceNameForFragment (artdaq::Fragment const &fragment) const
 Returns the product instance name for the specified fragment, based on the types that have been specified in the SetBasicTypes() and AddExtraType() methods. This does include the use of "container" types, if the container type mapping is part of the basic types. If no mapping is found, the specified unidentified_instance_name should be returned. Must be implemented by derived classes.
 

Additional Inherited Members

- Protected Attributes inherited from artdaq::FragmentNameHelper
std::map
< artdaq::Fragment::type_t,
std::string > 
type_map_
 Map relating Fragment Type to strings.
 
std::string unidentified_instance_name_
 The name to use for unknown Fragment types.
 

Detailed Description

Default implementation of FragmentNameHelper.

Definition at line 15 of file ArtdaqFragmentNameHelper.hh.

Constructor & Destructor Documentation

artdaq::ArtdaqFragmentNameHelper::ArtdaqFragmentNameHelper ( std::string  unidentified_instance_name,
std::vector< std::pair< artdaq::Fragment::type_t, std::string >>  extraTypes 
)

ArtdaqFragmentNameHelper Constructor.

Parameters
unidentified_instance_nameName to use for unidentified Fragments
extraTypesAdditional types to register

Definition at line 6 of file Artdaq_fragmentNameHelper.cc.


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