BufferedOutputPort::BufferedOutputPort(OutputPortHandler oph, sendPolicy_t pol) : port(oph) , policy(pol) , recieverInstances(dsGetNumReaders(port)) , portBuffers( (pol==labeledStream)? recieverInstances : 1 ) // labeled stream has one buffer per instance, other have one buffer to all , labelStreamGetLabel(NULL) , labelStreamHashFunc(NULL) , bytesSent(0) , nMessages(0) { }
int DCFilter::get_num_readers(string outPortName) { OutputPortHandler outPort = dsGetOutputPortByName((char *) outPortName.c_str()); return dsGetNumReaders(outPort); }