#ifndef __bbstdRelay_h_INCLUDED_H__
#define __bbstdRelay_h_INCLUDED_H__
-#include "bbtkUserBlackBox.h"
+#include "bbtkAtomicBlackBox.h"
namespace bbstd
{
-
+ //=======================================================================
template <class T>
- class /*BBTK_EXPORT*/ Relay
- :
- public bbtk::UserBlackBox
+ class Relay
+ :
+ public bbtk::AtomicBlackBox
{
- BBTK_USER_BLACK_BOX_INTERFACE(Relay,bbtk::UserBlackBox);
+ BBTK_TEMPLATE_BLACK_BOX_INTERFACE(Relay,bbtk::AtomicBlackBox,T);
BBTK_DECLARE_INPUT(In,T);
BBTK_DECLARE_OUTPUT(Out,T);
BBTK_PROCESS(Process);
protected:
void Process() { bbSetOutputOut ( bbGetInputIn() ); }
};
-
+ //=======================================================================
- BBTK_BEGIN_DESCRIBE_TEMPLATE_BLACK_BOX(Relay);
+ //=======================================================================
+ BBTK_BEGIN_DESCRIBE_TEMPLATE_BLACK_BOX(Relay,bbtk::AtomicBlackBox);
BBTK_NAME(bbtk::HumanTypeName<T>()+"Relay");
- BBTK_AUTHOR("laurent.guigues@creatis.insa-lyon.fr");
- BBTK_DESCRIPTION("Relays a "+bbtk::TypeName<T>());
+ 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_TEMPLATE_INPUT(Relay,In,"Input",T);
BBTK_TEMPLATE_OUTPUT(Relay,Out,"Output",T);
BBTK_END_DESCRIBE_TEMPLATE_BLACK_BOX(Relay);
+ //=======================================================================
}
// namespace bbstd