FACT++  1.0
void ConnectionSQM::ConnectionEstablished ( )
inlineprivate

Definition at line 223 of file sqmctrl.cc.

References HandleRead(), and HandleRequestTrigger().

224  {
225  fValid = false;
226  fFirstMessage = true;
227 
228  // Empty a possible buffer first before we start reading
229  // otherwise reading and writing might not be consecutive
230  async_read_until(*this, fBuffer, '\n',
231  boost::bind(&ConnectionSQM::HandleRead, this,
232  dummy::error, dummy::bytes_transferred));
233 
234  // If there was no immediate answer, send a request
235  fTrigger.expires_at(Time()+boost::posix_time::milliseconds(1000));
236  fTrigger.async_wait(boost::bind(&ConnectionSQM::HandleRequestTrigger,
237  this, dummy::error));
238  }
Adds some functionality to boost::posix_time::ptime for our needs.
Definition: Time.h:30
bool fValid
Definition: sqmctrl.cc:33
boost::asio::deadline_timer fTrigger
Definition: sqmctrl.cc:38
boost::asio::streambuf fBuffer
Definition: sqmctrl.cc:36
void HandleRequestTrigger(const bs::error_code &error)
Definition: sqmctrl.cc:172
bool fFirstMessage
Definition: sqmctrl.cc:32
void HandleRead(const boost::system::error_code &err, size_t bytes_received)
Definition: sqmctrl.cc:40

+ Here is the call graph for this function: