Exiv2
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Types | Public Member Functions | List of all members
Action::Print Class Reference

Print the Exif (or other metadata) of a file to stdout More...

#include <actions.hpp>

+ Inheritance diagram for Action::Print:
+ Collaboration diagram for Action::Print:

Public Types

typedef std::auto_ptr< PrintAutoPtr
 
typedef
Exiv2::ExifData::const_iterator(* 
EasyAccessFct )(const Exiv2::ExifData &ed)
 Type for an Exiv2 Easy access function.
 
- Public Types inherited from Action::Task
typedef std::auto_ptr< TaskAutoPtr
 Shortcut for an auto pointer.
 

Public Member Functions

virtual int run (const std::string &path)
 Application interface to perform a task. More...
 
AutoPtr clone () const
 
int printComment ()
 Print the Jpeg comment.
 
int printPreviewList ()
 Print list of available preview images.
 
int printSummary ()
 Print Exif summary information.
 
int printList ()
 Print Exif, IPTC and XMP metadata in user defined format.
 
bool grepTag (const std::string &key)
 Return true if key should be printed, else false.
 
int printMetadata (const Exiv2::Image *image)
 Print all metadata in a user defined format.
 
void printMetadatum (const Exiv2::Metadatum &md, const Exiv2::Image *image)
 Print a metadatum in a user defined format.
 
void printLabel (const std::string &label) const
 Print the label for a summary line.
 
int printTag (const Exiv2::ExifData &exifData, const std::string &key, const std::string &label="") const
 Print one summary line with a label (if provided) and requested data. A line break is printed only if a label is provided. More...
 
int printTag (const Exiv2::ExifData &exifData, EasyAccessFct easyAccessFct, const std::string &label) const
 Print one summary line with a label (if provided) and requested data. A line break is printed only if a label is provided. More...
 
- Public Member Functions inherited from Action::Task
virtual ~Task ()
 Virtual destructor.
 
AutoPtr clone () const
 Virtual copy construction.
 

Detailed Description

Print the Exif (or other metadata) of a file to stdout

Member Function Documentation

int Action::Print::printTag ( const Exiv2::ExifData exifData,
const std::string &  key,
const std::string &  label = "" 
) const

Print one summary line with a label (if provided) and requested data. A line break is printed only if a label is provided.

Returns
1 if a line was written, 0 if the key was not found.

References Exiv2::ExifData::end(), Exiv2::ExifData::findKey(), and printLabel().

Referenced by printSummary().

int Action::Print::printTag ( const Exiv2::ExifData exifData,
EasyAccessFct  easyAccessFct,
const std::string &  label 
) const

Print one summary line with a label (if provided) and requested data. A line break is printed only if a label is provided.

Returns
1 if a line was written, 0 if the information was not found.

References Exiv2::ExifData::end(), and printLabel().

int Action::Print::run ( const std::string &  path)
virtual

Application interface to perform a task.

Parameters
pathPath of the file to process.
Returns
0 if successful.

Implements Action::Task.

References Params::instance(), printComment(), printList(), printPreviewList(), and printSummary().


The documentation for this class was generated from the following files: