libopenraw
Public Member Functions | List of all members
OpenRaw::IO::File Class Reference

#include <file.h>

Inheritance diagram for OpenRaw::IO::File:
OpenRaw::IO::Stream

Public Member Functions

 File (const char *filename)
 
virtual Error open ()
 
virtual int close ()
 
virtual int seek (off_t offset, int whence)
 
virtual int read (void *buf, size_t count)
 
virtual off_t filesize ()
 
- Public Member Functions inherited from OpenRaw::IO::Stream
 Stream (const char *filename)
 
Error get_error ()
 
const std::string & get_path () const
 
uint8_t readByte () throw (Internals::IOException)
 

Additional Inherited Members

- Public Types inherited from OpenRaw::IO::Stream
typedef ::or_error Error
 
- Protected Member Functions inherited from OpenRaw::IO::Stream
void set_error (Error error)
 

Detailed Description

file IO stream

Definition at line 39 of file file.h.

Constructor & Destructor Documentation

OpenRaw::IO::File::File ( const char *  filename)

Contruct the file

Parameters
filenamethe full pathname for the file

Definition at line 29 of file file.cpp.

Member Function Documentation

int OpenRaw::IO::File::close ( )
virtual

close the file

Implements OpenRaw::IO::Stream.

Definition at line 49 of file file.cpp.

File::Error OpenRaw::IO::File::open ( )
virtual

open the file

Implements OpenRaw::IO::Stream.

Definition at line 40 of file file.cpp.

References OpenRaw::IO::Stream::get_path().

int OpenRaw::IO::File::read ( void *  buf,
size_t  count 
)
virtual

read in the file. Semantics are similar to POSIX

Implements OpenRaw::IO::Stream.

Definition at line 59 of file file.cpp.

int OpenRaw::IO::File::seek ( off_t  offset,
int  whence 
)
virtual

seek in the file. Semantics are similar to POSIX

Implements OpenRaw::IO::Stream.

Definition at line 54 of file file.cpp.


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