]> Creatis software - bbtk.git/blobdiff - packages/std/src/bbstdCreateArithmeticSuiteVector.h
Feature #1743 Add a box building a vector ot arithmetic suite values.
[bbtk.git] / packages / std / src / bbstdCreateArithmeticSuiteVector.h
diff --git a/packages/std/src/bbstdCreateArithmeticSuiteVector.h b/packages/std/src/bbstdCreateArithmeticSuiteVector.h
new file mode 100644 (file)
index 0000000..426eaa3
--- /dev/null
@@ -0,0 +1,37 @@
+#ifndef __bbstdCreateArithmeticSuiteVector_h_INCLUDED__
+#define __bbstdCreateArithmeticSuiteVector_h_INCLUDED__
+#include "bbstd_EXPORT.h"
+#include "bbtkAtomicBlackBox.h"
+#include "iostream"
+
+namespace bbstd
+{
+
+class bbstd_EXPORT CreateArithmeticSuiteVector
+ : 
+   public bbtk::AtomicBlackBox
+{
+  BBTK_BLACK_BOX_INTERFACE(CreateArithmeticSuiteVector,bbtk::AtomicBlackBox);
+  BBTK_DECLARE_INPUT(FirstValue,double);
+  BBTK_DECLARE_INPUT(Delta,double);
+  BBTK_DECLARE_INPUT(Size,int);
+  BBTK_DECLARE_OUTPUT(ArithmeticSuiteVector,std::vector<double>);
+  BBTK_PROCESS(Process);
+  void Process();
+};
+
+BBTK_BEGIN_DESCRIBE_BLACK_BOX(CreateArithmeticSuiteVector,bbtk::AtomicBlackBox);
+BBTK_NAME("CreateArithmeticSuiteVector");
+BBTK_AUTHOR("Claire Mouton");
+BBTK_DESCRIPTION("Creates a vector with the values of an arithmetic suite, given the first value, the difference between two consecutive elements (delta) and its size.");
+BBTK_CATEGORY("std");
+BBTK_INPUT(CreateArithmeticSuiteVector,FirstValue,"The first value of the vector.",double,"");
+BBTK_INPUT(CreateArithmeticSuiteVector,Delta,"The difference between two consecutive elements (Put 0 to get a constatn vector).",double,"");
+BBTK_INPUT(CreateArithmeticSuiteVector,Size,"Size of the vector to create.",int,"");
+BBTK_OUTPUT(CreateArithmeticSuiteVector,ArithmeticSuiteVector,"The created vector.",std::vector<double>,"");
+BBTK_END_DESCRIBE_BLACK_BOX(CreateArithmeticSuiteVector);
+}
+// EO namespace bbstd
+
+#endif // __bbstdCreateArithmeticSuiteVector_h_INCLUDED__
+