Tweak comment.
[libdcp.git] / src / asset.h
index b0cc450c999865e2f77dddd99c98a08fee961e92..6c0a9803adb9e47ead40255e0aefc380a0f20c3f 100644 (file)
@@ -26,6 +26,7 @@
 
 #include <string>
 #include <sigc++/sigc++.h>
+#include "types.h"
 
 namespace ASDCP {
        class WriterInfo;
@@ -42,12 +43,13 @@ class Asset
 {
 public:
        /** Construct an Asset.
-        *  @param mxf_path Pathname of MXF file.
+        *  @param directory Directory where MXF file is.
+        *  @param mxf_name Name of MXF file.
         *  @param progress Signal to inform of progress.
         *  @param fps Frames per second.
         *  @param length Length in frames.
         */
-       Asset (std::string mxf_path, sigc::signal1<void, float>* progress, int fps, int length);
+       Asset (std::string directory, std::string mxf_path, sigc::signal1<void, float>* progress, int fps, int length);
 
        /** Write details of the asset to a CPL stream.
         *  @param s Stream.
@@ -64,14 +66,24 @@ public:
         */
        void write_to_assetmap (std::ostream& s) const;
 
+       virtual std::list<std::string> equals (boost::shared_ptr<const Asset> other, EqualityOptions opt) const;
+
 protected:
+       friend class PictureAsset;
+       friend class SoundAsset;
+       
        /** Fill in a ADSCP::WriteInfo struct.
         *  @param w struct to fill in.
         */
        void fill_writer_info (ASDCP::WriterInfo* w) const;
 
-       /** Path to our MXF file */
-       std::string _mxf_path;
+       boost::filesystem::path mxf_path () const;
+       std::string digest () const;
+
+       /** Directory that our MXF file is in */
+       std::string _directory;
+       /** Name of our MXF file */
+       std::string _mxf_name;
        /** Signal to emit to report progress */
        sigc::signal1<void, float>* _progress;
        /** Frames per second */
@@ -80,8 +92,10 @@ protected:
        int _length;
        /** Our UUID */
        std::string _uuid;
+
+private:       
        /** Digest of our MXF */
-       std::string _digest;
+       mutable std::string _digest;
 };
 
 }