const correctness.
authorCarl Hetherington <cth@carlh.net>
Tue, 5 May 2020 20:27:54 +0000 (22:27 +0200)
committerCarl Hetherington <cth@carlh.net>
Wed, 6 May 2020 18:15:49 +0000 (20:15 +0200)
src/lib/kdm_with_metadata.h

index 7309ee2..6b9ff23 100644 (file)
@@ -33,7 +33,7 @@ class Cinema;
 class KDMWithMetadata
 {
 public:
-       KDMWithMetadata (dcp::NameFormat::Map const& name_values, boost::shared_ptr<Cinema> cinema)
+       KDMWithMetadata (dcp::NameFormat::Map const& name_values, boost::shared_ptr<const Cinema> cinema)
                : _name_values (name_values)
                , _cinema (cinema)
        {}
@@ -49,13 +49,13 @@ public:
 
        boost::optional<std::string> get (char k) const;
 
-       boost::shared_ptr<Cinema> cinema () const {
+       boost::shared_ptr<const Cinema> cinema () const {
                return _cinema;
        }
 
 private:
        dcp::NameFormat::Map _name_values;
-       boost::shared_ptr<Cinema> _cinema;
+       boost::shared_ptr<const Cinema> _cinema;
 };
 
 
@@ -104,7 +104,7 @@ template <class T>
 class SpecialKDMWithMetadata : public KDMWithMetadata
 {
 public:
-       SpecialKDMWithMetadata (dcp::NameFormat::Map const& name_values, boost::shared_ptr<Cinema> cinema, T k)
+       SpecialKDMWithMetadata (dcp::NameFormat::Map const& name_values, boost::shared_ptr<const Cinema> cinema, T k)
                : KDMWithMetadata (name_values, cinema)
                , kdm (k)
        {}