FACT++  1.0
template<class T>
void StateMachineFAD< T >::EnableConnection ( ConnectionFAD ptr,
bool  enable = true 
)
inlineprivate

Definition at line 1208 of file fadctrl.cc.

References Connection::GetEndpoint(), Connection::IsDisconnected(), Connection::PostClose(), Connection::StartConnect(), and str.

1209  {
1210  if (!enable)
1211  {
1212  ptr->PostClose(false);
1213  return;
1214  }
1215 
1216  if (!ptr->IsDisconnected())
1217  {
1218  ostringstream str;
1219  str << ptr->GetEndpoint();
1220 
1221  T::Warn("Connection to "+str.str()+" already in progress.");
1222  return;
1223  }
1224 
1225  ptr->StartConnect();
1226  }
void PostClose(bool restart=true)
Definition: Connection.cc:125
bool IsDisconnected() const
Definition: Connection.h:144
char str[80]
Definition: test_client.c:7
virtual void StartConnect()
Definition: Connection.cc:352
const boost::asio::ip::tcp::endpoint & GetEndpoint() const
Definition: Connection.h:153

+ Here is the call graph for this function: