Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | List of all members
art::PathContext Class Reference

#include <PathContext.h>

Public Member Functions

 PathContext (ScheduleContext const &scheduleContext, PathSpec const &pathSpec, std::vector< std::string > sortedModuleNames)
 
auto scheduleID () const
 
auto const & pathSpec () const
 
auto const & pathName () const
 
PathID pathID () const noexcept
 
bool contains (std::string const &module_label) const
 

Static Public Member Functions

static std::string end_path ()
 
static auto end_path_spec ()
 
static std::string art_path ()
 
static auto art_path_spec ()
 
static PathContext invalid ()
 

Private Member Functions

 PathContext ()=default
 

Private Attributes

ScheduleContext scheduleContext_ {ScheduleContext::invalid()}
 
PathSpec pathSpec_ {"", PathID::invalid()}
 
std::vector< std::stringsortedModuleLabels_ {}
 

Detailed Description

Definition at line 9 of file PathContext.h.

Constructor & Destructor Documentation

art::PathContext::PathContext ( )
explicitprivatedefault
art::PathContext::PathContext ( ScheduleContext const &  scheduleContext,
PathSpec const &  pathSpec,
std::vector< std::string sortedModuleNames 
)
inlineexplicit

Definition at line 37 of file PathContext.h.

40  : scheduleContext_{scheduleContext}
42  , sortedModuleLabels_{move(sortedModuleNames)}
43  {}
auto const & pathSpec() const
Definition: PathContext.h:57
std::vector< std::string > sortedModuleLabels_
Definition: PathContext.h:82
def move(depos, offset)
Definition: depos.py:107
ScheduleContext scheduleContext_
Definition: PathContext.h:80
PathSpec pathSpec_
Definition: PathContext.h:81

Member Function Documentation

static std::string art::PathContext::art_path ( )
inlinestatic

Definition at line 26 of file PathContext.h.

27  {
28  return "[art]";
29  }
static auto art::PathContext::art_path_spec ( )
inlinestatic

Definition at line 32 of file PathContext.h.

33  {
34  return PathSpec{art_path(), PathID::invalid()};
35  }
static std::string art_path()
Definition: PathContext.h:26
constexpr static auto invalid() noexcept
Definition: PathSpec.h:20
bool art::PathContext::contains ( std::string const &  module_label) const
inline

Definition at line 74 of file PathContext.h.

75  {
76  return cet::binary_search_all(sortedModuleLabels_, module_label);
77  }
std::vector< std::string > sortedModuleLabels_
Definition: PathContext.h:82
bool binary_search_all(FwdCont const &, Datum const &)
static std::string art::PathContext::end_path ( )
inlinestatic

Definition at line 14 of file PathContext.h.

15  {
16  return "end_path";
17  }
static auto art::PathContext::end_path_spec ( )
inlinestatic

Definition at line 20 of file PathContext.h.

21  {
22  return PathSpec{end_path(), PathID{0}};
23  }
static std::string end_path()
Definition: PathContext.h:14
static PathContext art::PathContext::invalid ( )
inlinestatic

Definition at line 46 of file PathContext.h.

47  {
48  return PathContext{};
49  }
PathContext()=default
PathID art::PathContext::pathID ( ) const
inlinenoexcept

Definition at line 68 of file PathContext.h.

69  {
70  return pathSpec_.path_id;
71  }
PathID path_id
Definition: PathSpec.h:49
PathSpec pathSpec_
Definition: PathContext.h:81
auto const& art::PathContext::pathName ( ) const
inline

Definition at line 63 of file PathContext.h.

64  {
65  return pathSpec_.name;
66  }
std::string name
Definition: PathSpec.h:48
PathSpec pathSpec_
Definition: PathContext.h:81
auto const& art::PathContext::pathSpec ( ) const
inline

Definition at line 57 of file PathContext.h.

58  {
59  return pathSpec_;
60  }
PathSpec pathSpec_
Definition: PathContext.h:81
auto art::PathContext::scheduleID ( ) const
inline

Definition at line 52 of file PathContext.h.

53  {
54  return scheduleContext_.id();
55  }
ScheduleContext scheduleContext_
Definition: PathContext.h:80

Member Data Documentation

PathSpec art::PathContext::pathSpec_ {"", PathID::invalid()}
private

Definition at line 81 of file PathContext.h.

ScheduleContext art::PathContext::scheduleContext_ {ScheduleContext::invalid()}
private

Definition at line 80 of file PathContext.h.

std::vector<std::string> art::PathContext::sortedModuleLabels_ {}
private

Definition at line 82 of file PathContext.h.


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