aGrUM  0.21.0
a C++ library for (probabilistic) graphical models
PRMReferenceSlot_tpl.h
Go to the documentation of this file.
1 /**
2  *
3  * Copyright (c) 2005-2021 by Pierre-Henri WUILLEMIN(@LIP6) & Christophe GONZALES(@AMU)
4  * info_at_agrum_dot_org
5  *
6  * This library is free software: you can redistribute it and/or modify
7  * it under the terms of the GNU Lesser General Public License as published by
8  * the Free Software Foundation, either version 3 of the License, or
9  * (at your option) any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public License
17  * along with this library. If not, see <http://www.gnu.org/licenses/>.
18  *
19  */
20 
21 
22 /**
23  * @file
24  * @brief Inline implementation of gum::PRMReferenceSlot
25  *
26  * @author Lionel TORTI and Pierre-Henri WUILLEMIN(@LIP6)
27  */
28 #include <agrum/PRM/elements/PRMReferenceSlot.h>
29 
30 namespace gum {
31  namespace prm {
32 
33  template < typename GUM_SCALAR >
34  PRMReferenceSlot< GUM_SCALAR >::PRMReferenceSlot(const std::string& name,
35  PRMClassElementContainer< GUM_SCALAR >& type,
36  bool isArray) :
37  PRMClassElement< GUM_SCALAR >(name),
38  _slotType_(type), _isArray_(isArray) {
39  GUM_CONSTRUCTOR(PRMReferenceSlot);
40  this->safeName_ = PRMObject::LEFT_CAST() + type.name() + PRMObject::RIGHT_CAST() + name;
41  }
42 
43  // Destructor.
44  template < typename GUM_SCALAR >
47  }
48 
49  template < typename GUM_SCALAR >
54  GUM_ERROR(FatalError, "illegal call to gum::ReferenceSlot copy constructor.")
55  }
56 
57  // Copy operator. Raise a FatalError.
58  template < typename GUM_SCALAR >
61  GUM_ERROR(FatalError, "illegal call to gum::ReferenceSlot copy operator.")
62  }
63 
64  template < typename GUM_SCALAR >
67  return this->prm_refslot;
68  }
69 
70  template < typename GUM_SCALAR >
72  return _slotType_;
73  }
74 
75  template < typename GUM_SCALAR >
78  return _slotType_;
79  }
80 
81  template < typename GUM_SCALAR >
83  return _isArray_;
84  }
85 
86  template < typename GUM_SCALAR >
88  GUM_ERROR(OperationNotAllowed, "This is a ReferenceSlot.")
89  }
90 
91  template < typename GUM_SCALAR >
93  GUM_ERROR(OperationNotAllowed, "This is a ReferenceSlot.")
94  }
95 
96  template < typename GUM_SCALAR >
98  GUM_ERROR(OperationNotAllowed, "This is a ReferenceSlot.")
99  }
100 
101  template < typename GUM_SCALAR >
103  GUM_ERROR(OperationNotAllowed, "This is a ReferenceSlot.")
104  }
105 
106  template < typename GUM_SCALAR >
108  GUM_ERROR(OperationNotAllowed, "This is a ReferenceSlot.")
109  }
110 
111 
112  template < typename GUM_SCALAR >
113  INLINE void
115 
116  template < typename GUM_SCALAR >
118  }
119 
120  } /* namespace prm */
121 } /* namespace gum */
INLINE void emplace(Args &&... args)
Definition: set_tpl.h:643
ParamScopeData(const std::string &s, const PRMReferenceSlot< GUM_SCALAR > &ref, Idx d)