SUNphi
1.0
|
#include <RelBind.hpp>
Public Types | |
using | Refs = Tuple< _Refs... > |
template<int I> | |
using | Ref = TupleElementType< I, Tuple< _Refs... >> |
using | NestedTk = typename RemRef< Ref< 0 >>::Tk |
Tens Kind of the bound type. | |
using | NestedTypes = typename NestedTk::types |
Types of the tensor kind. | |
using | BoundType = _BoundType |
Type to bind. | |
using | BoundToType = _BoundToType |
Type to which to bind. | |
using | Tk = typename NestedTk::template AllButType< BoundType > |
TensorKind of the bound expression. | |
using | Fund = typename RemRef< Ref< 0 >>::Fund |
Fundamental type. More... | |
using | ExtraDelims = IntSeq< extBoundToPos, extBoundToPos+1 > |
using | PosOfResTcsInRefsTk = PosOfTcsOfTkInListOfTks< Tk, typename RemRef< _Refs >::Tk... > |
using | PosOfResTcsPresInRefsTk = PosOfTcsOfTkPresInListOfTks< Tk, typename RemRef< _Refs >::Tk... > |
using | MergeableComps = NnarySmETCompsMergeability< Tuple< typename RemRef< _Refs >::MergeableComps... >, PosOfResTcsInRefsTk, ExtraDelims > |
Public Member Functions | |
template<typename Tref > | |
bool | isAliasing (const Tref &alias) const |
template<typename TC , int I = 0> | |
int | compSize () const |
decltype(auto) | getMaximallyMergedCompsView () |
template<typename Is > | |
decltype(auto) | getMergedCompsView () const |
template<typename... Ts> | |
decltype(auto) | getMergedCompsView (Ts &&...ts) |
template<typename... Args, typename Id , int... Head, int... Tail> | |
decltype(auto) | relBinderInternalEval (IntSeq< Head... >, IntSeq< Tail... >, const Id &id, const Tuple< Args... > &targs) const |
template<typename... Ts> | |
decltype(auto) | relBinderInternalEval (Ts &&...ts) |
template<typename... Args> | |
decltype(auto) | eval (const Args &...args) const |
template<typename... Ts> | |
decltype(auto) | eval (Ts &&...ts) |
template<typename Oth > | |
decltype(auto) | operator= (Oth &&oth) |
template<typename SMET , typename = EnableIf<isSame<Unqualified<SMET>,Unqualified<Ref<0>>>>> | |
RelBinder (SMET &&smet, _Ad &&adapter) | |
~RelBinder () | |
Destructor. | |
RelBinder< _BoundType, _BoundToType, _Ad, _Refs... > & | operator~ () |
const RelBinder< _BoundType, _BoundToType, _Ad, _Refs... > & | operator~ () const |
decltype(auto) | _refEvalByCompsName (IntSeq< I >, IntSeq< Pos... >, Tp &&targs) const |
< Components to get More... | |
decltype(auto) | _refEvalByCompsName (Ts &&...ts) |
decltype(auto) | refEvalByCompsName (Tp &&targs) const |
< Components to get More... | |
decltype(auto) | refEvalByCompsName (Tp &&targs) |
decltype(auto) | evalThroughRepresentativeFunctionPassingCompsByName (IntSeq< I... >, const Args &...args) const |
< Components to get More... | |
decltype(auto) | evalThroughRepresentativeFunctionPassingCompsByName (Ts &&...ts) |
decltype(auto) | operator() (Oth &&...oth) |
decltype(auto) | operator() (Oth &&...oth) const |
Static Public Member Functions | |
template<typename Is , typename = EnableIf<isIntSeq<Is>>> | |
static constexpr void | assertMergeableWith () |
Public Attributes | |
Tuple< Reference< _Refs >... > | refs |
Static Public Attributes | |
static constexpr int | NSmET = 1 |
static constexpr bool | isStoring = false |
static constexpr bool | isAssignable = Unqualified<Ref< 0 >>::isAssignable |
static constexpr int | extBoundToPos |
Position inside the external TensKind to which to bind. More... | |
Private Types | |
using | absBinder = Binder< _BoundType, Ref< 0 >> |
Dummy type, in which the _BoundType is absolutely bound. | |
Private Attributes | |
AddPointerIfFunction< _Ad > | adapter |
Static Private Attributes | |
static constexpr int | boundPos |
Position inside the reference of the TensKind got by the bounder. More... | |
static constexpr int | boundToPos |
Position inside the reference of the TensKind to which to bind. More... | |
Class to bind a component of a SmET
The first type is the bound (invisible) one, the second one is the free (visible) one
Definition at line 42 of file RelBind.hpp.
using SUNphi::RelBinder< _BoundType, _BoundToType, _Ad, _Refs >::ExtraDelims = IntSeq<extBoundToPos,extBoundToPos+1> |
Additional delimiters
Definition at line 113 of file RelBind.hpp.
using SUNphi::RelBinder< _BoundType, _BoundToType, _Ad, _Refs >::Fund = typename RemRef<Ref< 0 >>::Fund |
using SUNphi::RelBinder< _BoundType, _BoundToType, _Ad, _Refs >::MergeableComps = NnarySmETCompsMergeability< Tuple<typename RemRef<_Refs>::MergeableComps...>, PosOfResTcsInRefsTk, ExtraDelims> |
List of points where the TensKind
can be split
Using MergingDelimsForRefs
and ExtraDelims
to determine the mergability
Definition at line 117 of file RelBind.hpp.
using SUNphi::RelBinder< _BoundType, _BoundToType, _Ad, _Refs >::PosOfResTcsInRefsTk = PosOfTcsOfTkInListOfTks<Tk,typename RemRef<_Refs>::Tk...> |
Position of all the Result TensComp
in each Refs
Tk
Definition at line 115 of file RelBind.hpp.
using SUNphi::RelBinder< _BoundType, _BoundToType, _Ad, _Refs >::PosOfResTcsPresInRefsTk = PosOfTcsOfTkPresInListOfTks<Tk,typename RemRef<_Refs>::Tk...> |
Position of all the Result TensComp
present in each Refs
Tk
Definition at line 115 of file RelBind.hpp.
using SUNphi::RelBinder< _BoundType, _BoundToType, _Ad, _Refs >::Ref = TupleElementType<I,Tuple<_Refs...>> |
Type of I-th SmET
Definition at line 48 of file RelBind.hpp.
using SUNphi::RelBinder< _BoundType, _BoundToType, _Ad, _Refs >::Refs = Tuple<_Refs...> |
Type of the binding references
Definition at line 48 of file RelBind.hpp.
|
inlineexplicit |
Constructor taking a universal reference and the id
smet | Reference to bind |
adapter | Adapting function |
Definition at line 197 of file RelBind.hpp.
|
inlineinherited |
< Components to get
Evaluate the I-th reference, getting from the Tuple
targs the element Pos
Internal implementation
Definition at line 54 of file NnarySmET.hpp.
|
inlineinherited |
Overload the _refEvalByCompsName
const method passing all args
ts | Arguments |
Definition at line 61 of file NnarySmET.hpp.
|
inlinestatic |
Assert that a given merging condition is valid
Definition at line 117 of file RelBind.hpp.
|
inline |
|
inline |
Evaluator, external interface
Pass to the internal implementation the integer sequence needed to deal properly with the insertion of the arg in the correct position
Value of the boundTo component
Value of the bound component
args | Components to get |
Definition at line 151 of file RelBind.hpp.
|
inline |
Overload the eval
const method passing all args
ts | Arguments |
Definition at line 188 of file RelBind.hpp.
|
inlineinherited |
< Components to get
Evaluate the result by calling a representative function
The result is obtained after splitting the components, identifying them trough the name of each TensComp
Definition at line 93 of file NnarySmET.hpp.
|
inlineinherited |
Overload the evalThroughRepresentativeFunctionPassingCompsByName
const method passing all args
ts | Arguments |
Definition at line 101 of file NnarySmET.hpp.
|
inline |
Returns the maximal possible merged comps view
Definition at line 117 of file RelBind.hpp.
|
inline |
Insert the position of bound component shifting by 1 afterwards
Definition at line 120 of file RelBind.hpp.
|
inline |
Overload the getMergedCompsView
const method passing all args
ts | Arguments |
Definition at line 120 of file RelBind.hpp.
|
inline |
Forward aliasing check to the references
Definition at line 105 of file RelBind.hpp.
|
inlineinherited |
Implements the call operator via CRTP
oth | Other quantit |
Definition at line 289 of file BaseSmET.hpp.
|
inlineinherited |
Implements the const call operator via CRTP
< Other quantit
Definition at line 290 of file BaseSmET.hpp.
|
inline |
|
inlineinherited |
Constant cast operator to class T
Definition at line 46 of file NnarySmET.hpp.
|
inlineinherited |
Cast operator to class T
Definition at line 46 of file NnarySmET.hpp.
|
inlineinherited |
< Components to get
Evaluate the I-th reference, getting from the Tuple
targs the element Pos
External implementation, using PosOfResTcsPresInRefsTk
to dispatch components
Position of TensComp
of the reference Tk present in thr result
Definition at line 68 of file NnarySmET.hpp.
|
inlineinherited |
Evaluate the I-th reference, getting from the Tuple
targs the element Pos
Non const version
Definition at line 82 of file NnarySmET.hpp.
|
inline |
Evaluator for RelBinder
Internal Evaluator, inserting the id at the correct position in the list of args. Check on type B is omitted, as the function is called only from an already checked smet
id | Component to insert |
targs | Components to get |
Definition at line 131 of file RelBind.hpp.
|
inline |
Overload the relBinderInternalEval
const method passing all args
ts | Arguments |
Definition at line 143 of file RelBind.hpp.
|
private |
Adapter, used to remap the boundTo component
The pointer is needed to allow non-member function to be passed as adaptor, see: https://stackoverflow.com/questions/13233213/can-a-function-type-be-a-class-template-parameter
Definition at line 87 of file RelBind.hpp.
|
staticprivate |
Position inside the reference of the TensKind got by the bounder.
Definition at line 75 of file RelBind.hpp.
|
staticprivate |
Position inside the reference of the TensKind to which to bind.
Definition at line 79 of file RelBind.hpp.
|
static |
Position inside the external TensKind to which to bind.
Definition at line 110 of file RelBind.hpp.
|
static |
Returns whether this SmET
can be the left hand of an assignement
As assignable as ref 0
Definition at line 103 of file RelBind.hpp.
|
static |
Returns whether this SmET is storing
This SmET
is not storing
Definition at line 101 of file RelBind.hpp.
|
static |
Number or SmET
to act upon
Definition at line 48 of file RelBind.hpp.
Tuple<Reference<_Refs>...> SUNphi::RelBinder< _BoundType, _BoundToType, _Ad, _Refs >::refs |
Reference to the 1 object
Definition at line 48 of file RelBind.hpp.