diff options
Diffstat (limited to 'src/lib/image_proxy.h')
| -rw-r--r-- | src/lib/image_proxy.h | 18 |
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); |
