}
bool
-Asset::equals (boost::shared_ptr<const Asset> other, EqualityOptions, function<void (NoteType, string)> note) const
+Asset::equals (boost::shared_ptr<const Asset> other, EqualityOptions, NoteHandler note) const
{
if (_hash != other->_hash) {
note (DCP_ERROR, "Asset: hashes differ");
virtual bool equals (
boost::shared_ptr<const Asset> other,
EqualityOptions opt,
- boost::function<void (NoteType, std::string)> note
+ NoteHandler note
) const;
/** Write details of the asset to a ASSETMAP.
}
bool
-CPL::equals (shared_ptr<const Asset> other, EqualityOptions opt, boost::function<void (NoteType, string)> note) const
+CPL::equals (shared_ptr<const Asset> other, EqualityOptions opt, NoteHandler note) const
{
shared_ptr<const CPL> other_cpl = dynamic_pointer_cast<const CPL> (other);
if (!other_cpl) {
bool equals (
boost::shared_ptr<const Asset> other,
EqualityOptions options,
- boost::function<void (NoteType, std::string)> note
+ NoteHandler note
) const;
void add (boost::shared_ptr<Reel> reel);
}
bool
-DCP::equals (DCP const & other, EqualityOptions opt, boost::function<void (NoteType, string)> note) const
+DCP::equals (DCP const & other, EqualityOptions opt, NoteHandler note) const
{
list<shared_ptr<CPL> > a = cpls ();
list<shared_ptr<CPL> > b = other.cpls ();
* @param note Functor to handle notes made by the equality operation.
* @return true if the DCPs are equal according to EqualityOptions, otherwise false.
*/
- bool equals (DCP const & other, EqualityOptions options, boost::function<void (NoteType, std::string)> note) const;
+ bool equals (DCP const & other, EqualityOptions options, NoteHandler note) const;
void add (boost::shared_ptr<Asset> asset);
using std::list;
using std::string;
using boost::shared_ptr;
-using boost::function;
using boost::optional;
using boost::dynamic_pointer_cast;
using namespace dcp;
}
bool
-InteropSubtitleContent::equals (shared_ptr<const Asset> other_asset, EqualityOptions options, function<void (NoteType, std::string)> note) const
+InteropSubtitleContent::equals (shared_ptr<const Asset> other_asset, EqualityOptions options, NoteHandler note) const
{
if (!SubtitleContent::equals (other_asset, options, note)) {
return false;
bool equals (
boost::shared_ptr<const Asset>,
EqualityOptions,
- boost::function<void (NoteType, std::string)> note
+ NoteHandler note
) const;
std::list<boost::shared_ptr<LoadFont> > load_font_nodes () const;
}
bool
-MonoPictureMXF::equals (shared_ptr<const Asset> other, EqualityOptions opt, boost::function<void (NoteType, string)> note) const
+MonoPictureMXF::equals (shared_ptr<const Asset> other, EqualityOptions opt, NoteHandler note) const
{
if (!dynamic_pointer_cast<const MonoPictureMXF> (other)) {
return false;
bool equals (
boost::shared_ptr<const Asset> other,
EqualityOptions opt,
- boost::function<void (NoteType, std::string)> note
+ NoteHandler note
) const;
boost::shared_ptr<const MonoPictureFrame> get_frame (int n) const;
}
bool
-MXF::equals (shared_ptr<const Asset> other, EqualityOptions opt, boost::function<void (NoteType, string)> note) const
+MXF::equals (shared_ptr<const Asset> other, EqualityOptions opt, NoteHandler note) const
{
if (!Content::equals (other, opt, note)) {
return false;
bool equals (
boost::shared_ptr<const Asset> other,
EqualityOptions opt,
- boost::function<void (NoteType, std::string)> note
+ NoteHandler note
) const;
/** Fill in a ADSCP::WriteInfo struct.
bool
PictureMXF::descriptor_equals (
- ASDCP::JP2K::PictureDescriptor const & a, ASDCP::JP2K::PictureDescriptor const & b, boost::function<void (NoteType, string)> note
+ ASDCP::JP2K::PictureDescriptor const & a, ASDCP::JP2K::PictureDescriptor const & b, NoteHandler note
) const
{
if (
bool
PictureMXF::frame_buffer_equals (
- int frame, EqualityOptions opt, boost::function<void (NoteType, string)> note,
+ int frame, EqualityOptions opt, NoteHandler note,
uint8_t const * data_A, unsigned int size_A, uint8_t const * data_B, unsigned int size_B
) const
{
protected:
bool frame_buffer_equals (
- int frame, EqualityOptions opt, boost::function<void (NoteType, std::string)> note,
+ int frame, EqualityOptions opt, NoteHandler note,
uint8_t const * data_A, unsigned int size_A, uint8_t const * data_B, unsigned int size_B
) const;
bool descriptor_equals (
ASDCP::JP2K::PictureDescriptor const & a,
ASDCP::JP2K::PictureDescriptor const & b,
- boost::function<void (NoteType, std::string)>
+ NoteHandler note
) const;
void read_picture_descriptor (ASDCP::JP2K::PictureDescriptor const &);
}
bool
-Reel::equals (boost::shared_ptr<const Reel> other, EqualityOptions opt, boost::function<void (NoteType, string)> note) const
+Reel::equals (boost::shared_ptr<const Reel> other, EqualityOptions opt, NoteHandler note) const
{
if ((_main_picture && !other->_main_picture) || (!_main_picture && other->_main_picture)) {
note (DCP_ERROR, "Reel: assets differ");
bool encrypted () const;
- bool equals (boost::shared_ptr<const Reel> other, EqualityOptions opt, boost::function<void (NoteType, std::string)> notes) const;
+ bool equals (boost::shared_ptr<const Reel> other, EqualityOptions opt, NoteHandler notes) const;
void add (DecryptedKDM const &);
}
bool
-ReelAsset::equals (shared_ptr<const ReelAsset> other, EqualityOptions opt, boost::function<void (NoteType, std::string)> note) const
+ReelAsset::equals (shared_ptr<const ReelAsset> other, EqualityOptions opt, NoteHandler note) const
{
if (_annotation_text != other->_annotation_text) {
stringstream s;
ReelAsset (boost::shared_ptr<const cxml::Node>);
virtual void write_to_cpl (xmlpp::Node* node, Standard standard) const;
- virtual bool equals (boost::shared_ptr<const ReelAsset>, EqualityOptions, boost::function<void (NoteType, std::string)>) const;
+ virtual bool equals (boost::shared_ptr<const ReelAsset>, EqualityOptions, NoteHandler) const;
/** @return a Ref to our actual content */
Ref<Content>& content () {
}
bool
-ReelPictureAsset::equals (shared_ptr<const ReelAsset> other, EqualityOptions opt, boost::function<void (NoteType, std::string)> note) const
+ReelPictureAsset::equals (shared_ptr<const ReelAsset> other, EqualityOptions opt, NoteHandler note) const
{
if (!ReelAsset::equals (other, opt, note)) {
return false;
ReelPictureAsset (boost::shared_ptr<const cxml::Node>);
virtual void write_to_cpl (xmlpp::Node* node, Standard standard) const;
- virtual bool equals (boost::shared_ptr<const ReelAsset>, EqualityOptions, boost::function<void (NoteType, std::string)>) const;
+ virtual bool equals (boost::shared_ptr<const ReelAsset>, EqualityOptions, NoteHandler) const;
boost::shared_ptr<PictureMXF> mxf () {
return boost::dynamic_pointer_cast<PictureMXF> (_content.object ());
}
bool
-SoundMXF::equals (shared_ptr<const Asset> other, EqualityOptions opt, boost::function<void (NoteType, string)> note) const
+SoundMXF::equals (shared_ptr<const Asset> other, EqualityOptions opt, NoteHandler note) const
{
if (!MXF::equals (other, opt, note)) {
return false;
bool equals (
boost::shared_ptr<const Asset> other,
EqualityOptions opt,
- boost::function<void (NoteType, std::string)> note
+ NoteHandler note
) const;
boost::shared_ptr<const SoundFrame> get_frame (int n) const;
}
bool
-StereoPictureMXF::equals (shared_ptr<const Asset> other, EqualityOptions opt, boost::function<void (NoteType, string)> note) const
+StereoPictureMXF::equals (shared_ptr<const Asset> other, EqualityOptions opt, NoteHandler note) const
{
if (!MXF::equals (other, opt, note)) {
return false;
bool equals (
boost::shared_ptr<const Asset> other,
EqualityOptions opt,
- boost::function<void (NoteType, std::string)> note
+ NoteHandler note
) const;
boost::shared_ptr<const StereoPictureFrame> get_frame (int n) const;
using std::cout;
using boost::shared_ptr;
using boost::optional;
-using boost::function;
using boost::dynamic_pointer_cast;
using namespace dcp;
}
bool
-SubtitleContent::equals (shared_ptr<const Asset> other_asset, EqualityOptions options, function<void (NoteType, std::string)> note) const
+SubtitleContent::equals (shared_ptr<const Asset> other_asset, EqualityOptions options, NoteHandler note) const
{
if (!Asset::equals (other_asset, options, note)) {
return false;
bool equals (
boost::shared_ptr<const Asset>,
EqualityOptions,
- boost::function<void (NoteType, std::string)> note
+ NoteHandler note
) const;
std::string language () const {
#define LIBDCP_TYPES_H
#include <boost/shared_ptr.hpp>
+#include <boost/function.hpp>
#include <string>
namespace dcp
typedef std::pair<std::string, boost::shared_ptr<const parse::AssetMap> > PathAssetMap;
+typedef boost::function<void (NoteType, std::string)> NoteHandler;
+
+
}
#endif