#ifndef _CAPSERVER_MAINAPPLICATION_HPP_ #define _CAPSERVER_MAINAPPLICATION_HPP_ #ifndef _CAPSERVER_SOCKET_HEADER_HPP_ #include #endif #ifndef _SOCKET_WSADATA_HPP_ #include #endif #ifndef _CAPSERVER_SOCKETSERVER_HPP_ #include #endif #ifndef _CAPSERVER_PARAMS_HPP_ #include #endif #ifndef _VIDCAP_VIDREG_HPP_ #include #endif class MainApplication { public: MainApplication(); virtual ~MainApplication(); int run(int argc,char **argv); private: void message(const String &message); void message(const String &message,int arg); void message(const String &message,const String &arg); void handleServer(const String &host,int port,int timeout,int deviceIndex,bool retain,bool debug,bool showSrcDlg); void handleClient(const String &server,int port); void handleSettings(bool showSrcDlg); void displayUsage(void); WSASystem mWSASystem; Params mParams; }; inline void MainApplication::message(const String &message) { printf("%s\n",message.str()); } inline void MainApplication::message(const String &message,int arg) { printf("%s=%d\n",message.str(),arg); } inline void MainApplication::message(const String &message,const String &arg) { printf("%s=%s\n",message.str(),arg.str()); } #endif