#include "filter.h"
#include "ratio.h"
#include "types.h"
+#include "log.h"
#include "dcp_content_type.h"
#include "cinema_sound_processor.h"
#include "colour_conversion.h"
#include "dcp_video.h"
#include "config.h"
#include "exceptions.h"
-#include "server.h"
+#include "server_description.h"
#include "dcpomatic_socket.h"
#include "image.h"
#include "log.h"
#include "player.h"
#include "player_video.h"
#include "data.h"
+#include "server_description.h"
#include "compose.hpp"
#include <libcxml/cxml.h>
#include <boost/foreach.hpp>
#include "safe_stringstream.h"
#include "raw_convert.h"
#include "compose.hpp"
+#include "log.h"
#include <libcxml/cxml.h>
#include <boost/algorithm/string.hpp>
#include <boost/scoped_array.hpp>
#define DCPOMATIC_SERVER_H
/** @file src/server.h
- * @brief Class to describe a server to which we can send
- * encoding work, and a class to implement such a server.
+ * @brief Server class.
*/
-#include "log.h"
#include "exceptions.h"
-#include <libxml++/libxml++.h>
#include <boost/thread.hpp>
#include <boost/asio.hpp>
#include <boost/thread/condition.hpp>
-#include <boost/optional.hpp>
#include <string>
class Socket;
+class Log;
namespace cxml {
class Node;
}
-/** @class ServerDescription
- * @brief Class to describe a server to which we can send encoding work.
+/** @class Server
+ * @brief A class to run a server which can accept requests to perform JPEG2000
+ * encoding work.
*/
-class ServerDescription
-{
-public:
- ServerDescription ()
- : _host_name ("")
- , _threads (1)
- {}
-
- /** @param h Server host name or IP address in string form.
- * @param t Number of threads to use on the server.
- */
- ServerDescription (std::string h, int t)
- : _host_name (h)
- , _threads (t)
- {}
-
- /* Default copy constructor is fine */
-
- /** @return server's host name or IP address in string form */
- std::string host_name () const {
- return _host_name;
- }
-
- /** @return number of threads to use on the server */
- int threads () const {
- return _threads;
- }
-
- void set_host_name (std::string n) {
- _host_name = n;
- }
-
- void set_threads (int t) {
- _threads = t;
- }
-
-private:
- /** server's host name */
- std::string _host_name;
- /** number of threads to use on the server */
- int _threads;
-};
-
class Server : public ExceptionStore, public boost::noncopyable
{
public:
--- /dev/null
+/*
+ Copyright (C) 2012 Carl Hetherington <cth@carlh.net>
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+
+*/
+
+/** @class ServerDescription
+ * @brief Class to describe a server to which we can send encoding work.
+ */
+class ServerDescription
+{
+public:
+ ServerDescription ()
+ : _host_name ("")
+ , _threads (1)
+ {}
+
+ /** @param h Server host name or IP address in string form.
+ * @param t Number of threads to use on the server.
+ */
+ ServerDescription (std::string h, int t)
+ : _host_name (h)
+ , _threads (t)
+ {}
+
+ /* Default copy constructor is fine */
+
+ /** @return server's host name or IP address in string form */
+ std::string host_name () const {
+ return _host_name;
+ }
+
+ /** @return number of threads to use on the server */
+ int threads () const {
+ return _threads;
+ }
+
+ void set_host_name (std::string n) {
+ _host_name = n;
+ }
+
+ void set_threads (int t) {
+ _threads = t;
+ }
+
+private:
+ /** server's host name */
+ std::string _host_name;
+ /** number of threads to use on the server */
+ int _threads;
+};
#include "util.h"
#include "config.h"
#include "cross.h"
+#include "server_description.h"
#include "dcpomatic_socket.h"
#include "raw_convert.h"
#include <libcxml/cxml.h>
*/
-#include <boost/thread.hpp>
-#include <wx/taskbar.h>
-#include <wx/icon.h>
#include "wx/wx_util.h"
#include "lib/util.h"
#include "lib/server.h"
#include "lib/config.h"
+#include "lib/log.h"
+#include <wx/taskbar.h>
+#include <wx/icon.h>
+#include <boost/thread.hpp>
using std::cout;
using std::string;
*/
-#include <iostream>
-#include <iomanip>
-#include <exception>
-#include <getopt.h>
#include "lib/ratio.h"
#include "lib/film.h"
#include "lib/filter.h"
#include "lib/player.h"
#include "lib/player_video.h"
#include "lib/data.h"
+#include "lib/server_description.h"
+#include <getopt.h>
+#include <iostream>
+#include <iomanip>
+#include <exception>
using std::cout;
using std::cerr;
#include "servers_list_dialog.h"
#include "wx_util.h"
#include "lib/server_finder.h"
+#include "lib/server_description.h"
#include <boost/lexical_cast.hpp>
#include <boost/foreach.hpp>
*/
+#include "lib/server.h"
#include <wx/wx.h>
#include <wx/listctrl.h>
-#include "lib/server.h"
+#include <boost/signals2.hpp>
class ServersListDialog : public wxDialog
{
* encoded data to check that they are the same.
*/
-#include <boost/test/unit_test.hpp>
-#include <boost/thread.hpp>
#include "lib/server.h"
#include "lib/image.h"
#include "lib/cross.h"
#include "lib/player_video.h"
#include "lib/raw_image_proxy.h"
#include "lib/data.h"
+#include "lib/server_description.h"
+#include "lib/log.h"
+#include <boost/test/unit_test.hpp>
+#include <boost/thread.hpp>
using std::list;
using boost::shared_ptr;