Go to the documentation of this file.
10 #ifndef vtk_m_cont_UncertainCellSet_h
11 #define vtk_m_cont_UncertainCellSet_h
37 template <
typename CellSetList>
43 "Cannot use vtkm::ListUniversal with UncertainCellSet.");
51 template <
typename CellSetType>
62 template <
typename OtherCellSetList>
80 template <
typename Functor,
typename... Args>
83 this->CastAndCallForTypes<CellSetList>(std::forward<Functor>(functor),
84 std::forward<Args>(args)...);
89 template <
typename NewCellSetList>
95 template <
typename NewCellSetList>
104 template <
typename CellSetList>
107 using DynamicTag = vtkm::cont::internal::DynamicTransformTagCastAndCall;
124 template <
typename CellSetList>
125 struct SerializableTypeString<
vtkm::cont::UncertainCellSet<CellSetList>>
141 struct UncertainCellSetSerializeFunctor
143 template <
typename CellSetType>
144 void operator()(
const CellSetType& cs, BinaryBuffer& bb)
const
147 vtkmdiy::save(bb, cs);
151 struct UncertainCellSetDeserializeFunctor
153 template <
typename CellSetType>
154 void operator()(CellSetType,
156 const std::string& typeString,
158 BinaryBuffer& bb)
const
162 CellSetType knownCellSet;
164 unknownCellSet = knownCellSet;
172 template <
typename CellSetList>
173 struct Serialization<
vtkm::cont::UncertainCellSet<CellSetList>>
178 static VTKM_CONT void save(BinaryBuffer& bb,
const Type& obj)
180 obj.CastAndCall(internal::UncertainCellSetSerializeFunctor{}, bb);
185 std::string typeString;
188 bool success =
false;
190 internal::UncertainCellSetDeserializeFunctor{}, CellSetList{}, obj, typeString, success, bb);
195 "Error deserializing Unknown/UncertainCellSet. Message TypeString: " + typeString);
204 #endif //vtk_m_cont_UncertainCellSet_h
VTKM_CONT UncertainCellSet(const UncertainCellSet< OtherCellSetList > &src)
Definition: UncertainCellSet.h:63
VTKM_CONT Thisclass NewInstance() const
Create a new cell set of the same type as this.
Definition: UncertainCellSet.h:73
Groups connected points that have the same field value.
Definition: Atomic.h:19
VTKM_SUPPRESS_EXEC_WARNINGS VTKM_EXEC_CONT auto Get(const vtkm::Tuple< Ts... > &tuple) -> decltype(tuple.template Get< Index >())
Retrieve the object from a vtkm::Tuple at the given index.
Definition: Tuple.h:83
A CellSet of an uncertain type.
Definition: UncertainCellSet.h:38
VTKM_SUPPRESS_EXEC_WARNINGS VTKM_EXEC_CONT void ListForEach(Functor &&f, vtkm::List< Ts... >, Args &&... args)
Definition: List.h:720
A CellSet of an unknown type.
Definition: UnknownCellSet.h:48
This class is thrown when VTK-m encounters data of a type that is incompatible with the current opera...
Definition: ErrorBadType.h:25
VTKM_CONT UncertainCellSet(const CellSetType &cellSet)
Definition: UncertainCellSet.h:52
VTKM_CONT UncertainCellSet(const vtkm::cont::UnknownCellSet &src)
Definition: UncertainCellSet.h:57
Definition: Particle.h:331
VTKM_SUPPRESS_EXEC_WARNINGS VTKM_EXEC T load(const U &u, vtkm::Id v)
Definition: FetchTagArrayDirectIn.h:36
#define VTKM_STATIC_ASSERT_MSG(condition, message)
Definition: StaticAssert.h:18
VTKM_CONT void CastAndCall(Functor &&functor, Args &&... args) const
Call a functor using the underlying cell set type.
Definition: UncertainCellSet.h:81
#define VTKM_CONT
Definition: ExportMacros.h:57
VTKM_CONT vtkm::cont::UncertainCellSet< CellSetList > ResetCellSetList() const
#define VTKM_IS_LIST(type)
Checks that the argument is a proper list.
Definition: List.h:64
#define VTKM_ALWAYS_EXPORT
Definition: ExportMacros.h:92