Wildmeshing Toolkit
MinOperationSequence.hpp
Go to the documentation of this file.
1 #pragma once
2 
3 #include "OperationSequence.hpp"
4 
5 #include <wmtk/Tuple.hpp>
6 
7 
8 namespace wmtk {
9 class Mesh;
10 
11 namespace operations {
12 
13 
15 {
16 public:
18  Mesh& mesh,
19  const std::vector<std::shared_ptr<Operation>>& operations = {});
21 
22 
23  inline void set_value_function(
24  const std::function<double(int64_t, const simplex::Simplex&)>& func)
25  {
26  m_value = func;
27  }
28 
29 
30 protected:
31  std::vector<simplex::Simplex> execute_operations(const simplex::Simplex& simplex) override;
32 
33 
34 private:
35  std::function<double(int64_t, const simplex::Simplex&)> m_value = nullptr;
36 };
37 
38 } // namespace operations
39 } // namespace wmtk
std::function< double(int64_t, const simplex::Simplex &)> m_value
void set_value_function(const std::function< double(int64_t, const simplex::Simplex &)> &func)
MinOperationSequence(Mesh &mesh, const std::vector< std::shared_ptr< Operation >> &operations={})
std::vector< simplex::Simplex > execute_operations(const simplex::Simplex &simplex) override
const Mesh & mesh() const
Definition: Operation.hpp:45
Definition: Accessor.hpp:6