Program: bbtk
Module: $RCSfile: bbstdRelay.h,v $
Language: C++
- Date: $Date: 2008/12/12 08:55:21 $
- Version: $Revision: 1.8 $
+ Date: $Date: 2009/05/14 14:43:38 $
+ Version: $Revision: 1.10 $
=========================================================================*/
/* ---------------------------------------------------------------------
BBTK_END_DESCRIBE_TEMPLATE_BLACK_BOX(Relay);
//=======================================================================
+ template <class T> void Relay<T>::bbUserSetDefaultValues() {}
+ template <class T> void Relay<T>::bbUserInitializeProcessing() {}
+ template <class T> void Relay<T>::bbUserFinalizeProcessing() {}
+
}
// namespace bbstd
+//=======================================================================
+// MACRO
+
+#define BBTK_DEFINE_RELAY_BLACK_BOX(TYPE,PACKAGE,NAME) \
+class bb ## PACKAGE ## _EXPORT NAME : public bbtk::AtomicBlackBox { \
+ BBTK_BLACK_BOX_INTERFACE(NAME,bbtk::AtomicBlackBox); \
+ BBTK_DECLARE_INPUT(In,TYPE); \
+ BBTK_DECLARE_OUTPUT(Out,TYPE); \
+ BBTK_PROCESS(Process); \
+ protected: \
+ void Process() { bbSetOutputOut ( bbGetInputIn() ); } \
+}; \
+BBTK_BEGIN_DESCRIBE_BLACK_BOX(NAME,bbtk::AtomicBlackBox);\
+BBTK_NAME(#NAME); \
+BBTK_AUTHOR("laurent.guigues at creatis.insa-lyon.fr"); \
+BBTK_CATEGORY("misc"); \
+BBTK_DESCRIPTION("Just copies the value of its input to its output. Usefull to plug an input of a complex box into different internal boxes."); \
+BBTK_INPUT(NAME,In,"Input",TYPE,"");\
+BBTK_OUTPUT(NAME,Out,"Output",TYPE,"");\
+BBTK_END_DESCRIBE_BLACK_BOX(NAME);
+
+//=======================================================================
+
#endif // __bbstdRelay_h_INCLUDED_H__