]> Creatis software - bbtk.git/blob - packages/std/src/bbstdStringTo.h
=== MAJOR RELEASE ====
[bbtk.git] / packages / std / src / bbstdStringTo.h
1 #ifndef __bbstdStringTo_h_INCLUDED__
2 #define __bbstdStringTo_h_INCLUDED__
3
4 #include "bbtkAtomicBlackBox.h"
5
6 namespace bbstd 
7
8   //=================================================================
9   // BlackBox declaration
10   template <class T>
11   class StringTo : public bbtk::AtomicBlackBox
12   {  
13     BBTK_TEMPLATE_BLACK_BOX_INTERFACE(StringTo,bbtk::AtomicBlackBox,T);
14     BBTK_DECLARE_INPUT(In,std::string);
15     BBTK_DECLARE_OUTPUT(Out,T);
16     BBTK_PROCESS(DoIt);
17     void DoIt(); 
18   };
19   //=================================================================
20
21   //=================================================================  
22   // BlackBox description
23   BBTK_BEGIN_DESCRIBE_TEMPLATE_BLACK_BOX(StringTo,bbtk::AtomicBlackBox);
24   BBTK_NAME("StringTo"+bbtk::HumanTypeName<T>());
25   BBTK_AUTHOR("laurent.guigues@creatis.insa-lyon.fr");
26   BBTK_DEFAULT_ADAPTOR();
27   BBTK_DESCRIPTION("Converts the content of the input string to a "
28                    +bbtk::HumanTypeName<T>()
29                    +" ("+bbtk::TypeName<T>()+")");
30   BBTK_TEMPLATE_INPUT(StringTo, In,"Input",std::string);
31   BBTK_TEMPLATE_OUTPUT(StringTo, Out,"Output",T);
32   BBTK_END_DESCRIBE_TEMPLATE_BLACK_BOX(StringTo);
33   //=================================================================
34   
35 } // namespace bbstd
36
37 #endif // __bbstdStringTo_h_INCLUDED__