ExaTN
tensor_op_create.hpp
1 
11 #ifndef EXATN_NUMERICS_TENSOR_OP_CREATE_HPP_
12 #define EXATN_NUMERICS_TENSOR_OP_CREATE_HPP_
13 
14 #include "tensor_basic.hpp"
15 #include "tensor_operation.hpp"
16 
17 namespace exatn{
18 
19 namespace numerics{
20 
22 public:
23 
25 
26  TensorOpCreate(const TensorOpCreate &) = default;
27  TensorOpCreate & operator=(const TensorOpCreate &) = default;
28  TensorOpCreate(TensorOpCreate &&) noexcept = default;
29  TensorOpCreate & operator=(TensorOpCreate &&) noexcept = default;
30  virtual ~TensorOpCreate() = default;
31 
33  virtual bool isSet() const override;
34 
36  virtual int accept(runtime::TensorNodeExecutor & node_executor,
37  runtime::TensorOpExecHandle * exec_handle) override;
38 
40  static std::unique_ptr<TensorOperation> createNew();
41 
43  void resetTensorElementType(TensorElementType element_type);
44 
46  inline TensorElementType getTensorElementType() const {
47  return element_type_;
48  }
49 
50 private:
51 
52  TensorElementType element_type_; //tensor element type
53 
54 };
55 
56 } //namespace numerics
57 
58 } //namespace exatn
59 
60 #endif //EXATN_NUMERICS_TENSOR_OP_CREATE_HPP_
exatn::numerics::TensorOpCreate::accept
virtual int accept(runtime::TensorNodeExecutor &node_executor, runtime::TensorOpExecHandle *exec_handle) override
Definition: tensor_op_create.cpp:27
exatn::numerics::TensorOpCreate::isSet
virtual bool isSet() const override
Definition: tensor_op_create.cpp:22
exatn::numerics::TensorOpCreate::getTensorElementType
TensorElementType getTensorElementType() const
Definition: tensor_op_create.hpp:46
exatn
Definition: DriverClient.hpp:10
exatn::numerics::TensorOpCreate::resetTensorElementType
void resetTensorElementType(TensorElementType element_type)
Definition: tensor_op_create.cpp:38
exatn::numerics::TensorOperation
Definition: tensor_operation.hpp:36
exatn::numerics::TensorOpCreate
Definition: tensor_op_create.hpp:21
exatn::runtime::TensorNodeExecutor
Definition: tensor_node_executor.hpp:36
exatn::numerics::TensorOpCreate::createNew
static std::unique_ptr< TensorOperation > createNew()
Definition: tensor_op_create.cpp:33