summaryrefslogtreecommitdiff
path: root/src/lib/image_proxy.h
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2014-06-02 12:06:20 +0100
committerCarl Hetherington <cth@carlh.net>2014-06-02 12:06:20 +0100
commit3574212ee42b2bd924eb95d5c0f4f69ec9e0a2f0 (patch)
tree24e46f4f566bfb98aa48e9dab602ec1c8d0591d6 /src/lib/image_proxy.h
parent24d54ea7fe1ba128cf8d3521d6738fc73a7c623e (diff)
parent8fb0f4eaa6d91ca9369f45dd7a57c29149edaaac (diff)
Merge master.
Diffstat (limited to 'src/lib/image_proxy.h')
-rw-r--r--src/lib/image_proxy.h18
1 files changed, 12 insertions, 6 deletions
diff --git a/src/lib/image_proxy.h b/src/lib/image_proxy.h
index 792fa004a..b499b3292 100644
--- a/src/lib/image_proxy.h
+++ b/src/lib/image_proxy.h
@@ -28,6 +28,7 @@
class Image;
class Socket;
+class Log;
namespace cxml {
class Node;
@@ -44,19 +45,24 @@ namespace cxml {
* the TIFF data TIFF until such a time that the actual image is needed.
* At this point, the class decodes the TIFF to an Image.
*/
-class ImageProxy
+class ImageProxy : public boost::noncopyable
{
public:
+ ImageProxy (boost::shared_ptr<Log> log);
+
virtual boost::shared_ptr<Image> image () const = 0;
virtual void add_metadata (xmlpp::Node *) const = 0;
virtual void send_binary (boost::shared_ptr<Socket>) const = 0;
+
+protected:
+ boost::shared_ptr<Log> _log;
};
class RawImageProxy : public ImageProxy
{
public:
- RawImageProxy (boost::shared_ptr<Image>);
- RawImageProxy (boost::shared_ptr<cxml::Node> xml, boost::shared_ptr<Socket> socket);
+ RawImageProxy (boost::shared_ptr<Image>, boost::shared_ptr<Log> log);
+ RawImageProxy (boost::shared_ptr<cxml::Node> xml, boost::shared_ptr<Socket> socket, boost::shared_ptr<Log> log);
boost::shared_ptr<Image> image () const;
void add_metadata (xmlpp::Node *) const;
@@ -69,8 +75,8 @@ private:
class MagickImageProxy : public ImageProxy
{
public:
- MagickImageProxy (boost::filesystem::path);
- MagickImageProxy (boost::shared_ptr<cxml::Node> xml, boost::shared_ptr<Socket> socket);
+ MagickImageProxy (boost::filesystem::path, boost::shared_ptr<Log> log);
+ MagickImageProxy (boost::shared_ptr<cxml::Node> xml, boost::shared_ptr<Socket> socket, boost::shared_ptr<Log> log);
boost::shared_ptr<Image> image () const;
void add_metadata (xmlpp::Node *) const;
@@ -81,4 +87,4 @@ private:
mutable boost::shared_ptr<Image> _image;
};
-boost::shared_ptr<ImageProxy> image_proxy_factory (boost::shared_ptr<cxml::Node> xml, boost::shared_ptr<Socket> socket);
+boost::shared_ptr<ImageProxy> image_proxy_factory (boost::shared_ptr<cxml::Node> xml, boost::shared_ptr<Socket> socket, boost::shared_ptr<Log> log);