]> SALOME platform Git repositories - modules/yacs.git/blob - src/engine/OutputDataStreamPort.hxx
Salome HOME
merge from branch DEV tag mergeto_trunk_04apr08
[modules/yacs.git] / src / engine / OutputDataStreamPort.hxx
1 #ifndef __OUTPUTDATASTREAMPORT_HXX__
2 #define __OUTPUTDATASTREAMPORT_HXX__
3
4 #include "OutPort.hxx"
5 #include "DataStreamPort.hxx"
6 #include "ConversionException.hxx"
7
8 #include <set>
9
10 namespace YACS
11 {
12   namespace ENGINE
13   {
14     class ElementaryNode;
15     class InputDataStreamPort;
16
17     class OutputDataStreamPort : public DataStreamPort, public OutPort
18     {
19       friend class ElementaryNode;
20     protected:
21       std::set<InputDataStreamPort *> _setOfInputDataStreamPort;
22     public:
23       static const char NAME[];
24     public:
25       OutputDataStreamPort(const OutputDataStreamPort& other, Node *newHelder);
26       OutputDataStreamPort(const std::string& name, Node *node, TypeCode* type);
27       virtual ~OutputDataStreamPort();
28       virtual OutputDataStreamPort *clone(Node *newHelder) const;
29       std::set<InPort *> edSetInPort() const;
30       bool isAlreadyLinkedWith(InPort *with) const;
31       virtual std::string getNameOfTypeOfCurrentInstance() const;
32       virtual bool addInPort(InPort *inPort) throw(Exception);
33       virtual bool edAddInputDataStreamPort(InputDataStreamPort *port) throw(ConversionException);
34       int edRemoveInputDataStreamPort(InputDataStreamPort *inPort, bool forward) throw(Exception);
35       void edRemoveAllLinksLinkedWithMe() throw(Exception);
36       int removeInPort(InPort *inPort, bool forward) throw(Exception);
37       virtual std::string typeName() {return "YACS__ENGINE__OutputDataStreamPort";}
38     private:
39       bool isAlreadyInSet(InputDataStreamPort *inPort) const;
40     };
41   }
42 }
43
44 #endif