Home || Visual Search || Applications || Architecture || Important Messages || OGL || Src

void Impala::Application::Videolympics::ServerConnector::Connect (  )  [inline]

Definition at line 79 of file ServerConnector.h.

References Impala::Application::Videolympics::GlobalStats::connected, ILOG_DEBUG, mConnected, mGlobalStats, mSecretPassword, mSocket, mStats, mVidolPort, mVidolServer, and CommunicatingSocket::send().

Referenced by Update().

00080     {
00081         if (mConnected)
00082             return;
00083         ILOG_DEBUG("establishing connection... ");
00084         try {
00085             mSocket = new TCPSocket(mVidolServer, mVidolPort);
00086         } catch (SocketException e) {
00087             ILOG_DEBUG("Could not connect to server.");
00088             mConnected = false;
00089             mStats.clear();
00090 
00091             mGlobalStats->connected = mConnected;
00092             return;
00093         }
00094         ILOG_DEBUG("connection established. Sending password...");
00095         mSocket->send(mSecretPassword.c_str(), strlen(mSecretPassword.c_str()));
00096         mConnected = true;
00097         mGlobalStats->connected = mConnected;
00098     }

Here is the call graph for this function:


Generated on Thu Jan 13 09:16:54 2011 for ImpalaSrc by  doxygen 1.5.1