Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Examples

Exiv2::ExvImage Class Reference

Helper class to access Exiv2 files. More...

#include <image.hpp>

Inheritance diagram for Exiv2::ExvImage:

Inheritance graph
[legend]
Collaboration diagram for Exiv2::ExvImage:

Collaboration graph
[legend]
List of all members.

Public Member Functions

Creators
 ExvImage (const std::string &path, bool create)
 Constructor that can either open an existing Exv image or create a new image from scratch. If a new image is to be created, any existing file is overwritten. Since the constructor can not return a result, callers should check the good method after object construction to determine success or failure.
 ~ExvImage ()
 Destructor.

Protected Member Functions

Accessors
int writeHeader (FILE *ofp) const
 Writes an Exv header (aka signature) to the file stream.
virtual bool isThisType (FILE *ifp, bool advance) const
 Determine if the content of the file stream is a Exv image. See base class for more details.

Friends

bool isExvType (FILE *ifp, bool advance)
 Check if the file ifp is an EXV file.

Detailed Description

Helper class to access Exiv2 files.


Constructor & Destructor Documentation

Exiv2::ExvImage::ExvImage const std::string &  path,
bool  create
 

Constructor that can either open an existing Exv image or create a new image from scratch. If a new image is to be created, any existing file is overwritten. Since the constructor can not return a result, callers should check the good method after object construction to determine success or failure.

Parameters:
path Full path to image file.
create Specifies if an existing file should be opened (false) or if a new file should be created (true).


Member Function Documentation

bool Exiv2::ExvImage::isThisType FILE *  ifp,
bool  advance
const [protected, virtual]
 

Determine if the content of the file stream is a Exv image. See base class for more details.

Parameters:
ifp Input file stream.
advance Flag indicating whether the read position in the stream should be advanced by the number of characters read to analyse the stream (true) or left at its original position (false). This applies only if the type matches.
Returns:
true if the file stream data matches a Exv image;
false if the stream data does not match;

Implements Exiv2::JpegBase.

int Exiv2::ExvImage::writeHeader FILE *  ofp  )  const [protected, virtual]
 

Writes an Exv header (aka signature) to the file stream.

Parameters:
ofp File stream that the header is written to.
Returns:
0 if successful;
4 if the output file can not be written to;

Implements Exiv2::JpegBase.


The documentation for this class was generated from the following files:
Generated on Sun Dec 12 17:54:07 2004 for Exiv2 by  doxygen 1.3.9.1