///////////////////////////////////////////////////////////////////// // // InRootProducer listens for events and runs on a socket. The first // receipt of a run invokes the BeginOfRun methods whilst second invokes // the EndOfRun methods on the proc block. // // Author: Stan Seibert(?) // P G Jones - contact person // // REVISION HISTORY: // ? : S. Seibert - First version // 2014-04-26 : P. Jones - Refactor run knowledge. // //////////////////////////////////////////////////////////////////// #ifndef __RAT_InNetProducer__ #define __RAT_InNetProducer__ #include #include class G4UIcmdWithAnInteger; class G4UIcommand; namespace RAT { class InNetProducer : public Producer { public: // Construct, set the ProcBlock to NULL InNetProducer(); // Construct with a ProcBlock // // block: block to use InNetProducer( ProcBlock* block ); // Override the G4UImessenger (from Producer) set method // // command: command to set // newValue: new value to set void SetNewValue( G4UIcommand* command, G4String newValue ); // Override the G4UImessenger (from Producer) get method // // command: command to query // Returns the command value G4String GetCurrentValue( G4UIcommand* command ); protected: // Listen for events on a socket // // port: port to listen on void Listen( const int port ); // Initialise the producer void Init(); G4UIcmdWithAnInteger *fListenCmd; // Command to listen on a port }; } // namespace RAT #endif