10 #ifndef vtk_m_exec_kokkos_internal_TaskBasic_h
11 #define vtk_m_exec_kokkos_internal_TaskBasic_h
27 template <
typename WType,
typename IType,
typename H
ints>
33 TaskBasic1D(
const WType& worklet,
const IType& invocation)
35 , Invocation(invocation)
39 void SetErrorMessageBuffer(
const vtkm::exec::internal::ErrorMessageBuffer& buffer)
41 this->Worklet.SetErrorMessageBuffer(buffer);
45 void operator()(
vtkm::Id index)
const
47 vtkm::exec::internal::detail::DoWorkletInvokeFunctor(
50 this->Worklet.GetThreadIndices(index,
51 this->Invocation.OutputToInputMap,
52 this->Invocation.VisitArray,
53 this->Invocation.ThreadToOutputMap,
54 this->Invocation.GetInputDomain()));
58 typename std::remove_const<WType>::type Worklet;
62 template <
typename WType,
typename H
ints>
68 explicit TaskBasic1D(
const WType& worklet)
73 void SetErrorMessageBuffer(
const vtkm::exec::internal::ErrorMessageBuffer& buffer)
75 this->Worklet.SetErrorMessageBuffer(buffer);
79 void operator()(
vtkm::Id index)
const { this->Worklet(index); }
82 typename std::remove_const<WType>::type Worklet;
85 template <
typename WType,
typename IType,
typename H
ints>
91 TaskBasic3D(
const WType& worklet,
const IType& invocation)
93 , Invocation(invocation)
97 void SetErrorMessageBuffer(
const vtkm::exec::internal::ErrorMessageBuffer& buffer)
99 this->Worklet.SetErrorMessageBuffer(buffer);
105 vtkm::exec::internal::detail::DoWorkletInvokeFunctor(
108 this->Worklet.GetThreadIndices(flatIdx,
110 this->Invocation.OutputToInputMap,
111 this->Invocation.VisitArray,
112 this->Invocation.ThreadToOutputMap,
113 this->Invocation.GetInputDomain()));
117 typename std::remove_const<WType>::type Worklet;
121 template <
typename WType,
typename H
ints>
127 explicit TaskBasic3D(
const WType& worklet)
132 void SetErrorMessageBuffer(
const vtkm::exec::internal::ErrorMessageBuffer& buffer)
134 this->Worklet.SetErrorMessageBuffer(buffer);
141 typename std::remove_const<WType>::type Worklet;
148 #endif //vtk_m_exec_kokkos_internal_TaskBasic_h