]> Creatis software - bbtk.git/blobdiff - packages/std/src/bbstdGetDoubleVectorSize.h
Feature #1742 Add a box providing the size of a vector (an example has been added).
[bbtk.git] / packages / std / src / bbstdGetDoubleVectorSize.h
diff --git a/packages/std/src/bbstdGetDoubleVectorSize.h b/packages/std/src/bbstdGetDoubleVectorSize.h
new file mode 100644 (file)
index 0000000..c3653ff
--- /dev/null
@@ -0,0 +1,33 @@
+#ifndef __bbstdGetDoubleVectorSize_h_INCLUDED__
+#define __bbstdGetDoubleVectorSize_h_INCLUDED__
+#include "bbstd_EXPORT.h"
+#include "bbtkAtomicBlackBox.h"
+#include "iostream"
+
+namespace bbstd
+{
+
+class bbstd_EXPORT GetDoubleVectorSize
+ : 
+   public bbtk::AtomicBlackBox
+{
+  BBTK_BLACK_BOX_INTERFACE(GetDoubleVectorSize,bbtk::AtomicBlackBox);
+  BBTK_DECLARE_INPUT(In,std::vector<double>);
+  BBTK_DECLARE_OUTPUT(VectorSize, double);
+  BBTK_PROCESS(Process);
+  void Process();
+};
+
+BBTK_BEGIN_DESCRIBE_BLACK_BOX(GetDoubleVectorSize,bbtk::AtomicBlackBox);
+BBTK_NAME("GetDoubleVectorSize");
+BBTK_AUTHOR("Claire Mouton");
+BBTK_DESCRIPTION("Retrieves the size of a vector of double.");
+BBTK_CATEGORY("std");
+BBTK_INPUT(GetDoubleVectorSize,In,"Input vector.",std::vector<double>,"");
+BBTK_OUTPUT(GetDoubleVectorSize,VectorSize,"The vector size.",double,"");
+BBTK_END_DESCRIBE_BLACK_BOX(GetDoubleVectorSize);
+}
+// EO namespace bbstd
+
+#endif // __bbstdGetDoubleVectorSize_h_INCLUDED__
+