Extract common code out into kdm_for_screen()
[dcpomatic.git] / src / lib / send_kdm_email_job.h
index e16716a6675cb60cb471f05b18325bda53fb96ed..452c76cee9060880c99ca6564cd1da564dd162ab 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2013 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2013-2019 Carl Hetherington <cth@carlh.net>
 
     This file is part of DCP-o-matic.
 
 */
 
 #include "job.h"
-#include "kdm_name_format.h"
+#include "kdm_with_metadata.h"
 #include <dcp/types.h>
+#include <dcp/name_format.h>
 #include <boost/filesystem.hpp>
 
-class Screen;
-class CinemaKDMs;
+namespace dcpomatic {
+       class Screen;
+}
+
 class Log;
 
 class SendKDMEmailJob : public Job
 {
 public:
        SendKDMEmailJob (
-               std::list<CinemaKDMs> cinema_kdms,
-               KDMNameFormat name_format,
-               NameFormat::Map name_values,
-               std::string cpl_name,
-               boost::shared_ptr<Log> log
+               std::list<std::list<KDMWithMetadataPtr> > kdms,
+               dcp::NameFormat container_name_format,
+               dcp::NameFormat filename_format,
+               std::string cpl_name
                );
+       ~SendKDMEmailJob ();
 
        std::string name () const;
        std::string json_name () const;
        void run ();
 
 private:
-       KDMNameFormat _name_format;
-       NameFormat::Map _name_values;
+       dcp::NameFormat _container_name_format;
+       dcp::NameFormat _filename_format;
        std::string _cpl_name;
-       std::list<CinemaKDMs> _cinema_kdms;
-       boost::shared_ptr<Log> _log;
+       std::list<std::list<KDMWithMetadataPtr> > _kdms;
 };