xc
SingleActionWrapper.h
1 // -*-c++-*-
2 //----------------------------------------------------------------------------
3 // xc utils library; general purpose classes and functions.
4 //
5 // Copyright (C) Luis C. PĂ©rez Tato
6 //
7 // XC utils is free software: you can redistribute it and/or modify
8 // it under the terms of the GNU General Public License as published by
9 // the Free Software Foundation, either version 3 of the License, or
10 // (at your option) any later version.
11 //
12 // This software is distributed in the hope that it will be useful, but
13 // WITHOUT ANY WARRANTY; without even the implied warranty of
14 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 // GNU General Public License for more details.
16 //
17 // You should have received a copy of the GNU General Public License
18 // along with this program.
19 // If not, see <http://www.gnu.org/licenses/>.
20 //----------------------------------------------------------------------------
21 //SingleActionWrapper.hxx
22 //Representative values of an action.
23 
24 #ifndef SINGLEACTIONWRAPPER_H
25 #define SINGLEACTIONWRAPPER_H
26 
27 #include "ActionWrapper.h"
28 #include "ActionRepresentativeValues.h"
29 
30 namespace cmb_acc{
31 
35  {
36  friend class ActionWrapperList;
37  protected:
40  SingleActionWrapper(const std::string &n="", const std::string &descrip="", ActionWrapperList *list= nullptr);
41  SingleActionWrapper(const Action &a, ActionWrapperList *list= nullptr,const std::string &nmb_comb_factors= "", const std::string &nmb_partial_safety_factors= "");
42  virtual std::string getName(void) const;
43  public:
44  std::vector<const Action *> getWrappedActions(void) const;
45  const Action *getAction(const size_t &) const;
46  virtual Action getRepresentativeValue(const LeadingActionInfo &) const;
47  const ActionRelationships &getRelaciones(void) const;
48  bool notDeterminant(void) const;
49  };
50 
51 } //fin namespace nmb_acc.
52 
53 #endif
List of representative values of actions (ActionWrapper objects).
Definition: ActionWrapperList.h:42
virtual Action getRepresentativeValue(const LeadingActionInfo &) const
Get the representative value of the action in the contest being pased as parameter.
Definition: SingleActionWrapper.cc:55
Routines to generate combinations of actions.
Wrapper for a single action.
Definition: SingleActionWrapper.h:34
SingleActionWrapper(const std::string &n="", const std::string &descrip="", ActionWrapperList *list=nullptr)
Default constructor.
Definition: SingleActionWrapper.cc:26
virtual std::string getName(void) const
Return the action name.
Definition: SingleActionWrapper.cc:38
Action or linear combination of actions.
Definition: Action.h:44
bool notDeterminant(void) const
Return true if the action cannot be determinant.
Definition: SingleActionWrapper.cc:66
Representative values of an action.
Definition: ActionRepresentativeValues.h:40
Information about the leading action.
Definition: LeadingActionInfo.h:35
Base class for action design values and action groups.
Definition: ActionWrapper.h:42
const Action * getAction(const size_t &) const
Return the action corresponding to the given index.
Definition: SingleActionWrapper.cc:49
Relationship of an action with the other ones.
Definition: ActionRelationships.h:37
std::vector< const Action * > getWrappedActions(void) const
Return pointers to the actions wrapped in this object.
Definition: SingleActionWrapper.cc:42
const ActionRelationships & getRelaciones(void) const
Return the relatioships with the other actions.
Definition: SingleActionWrapper.cc:62