openMSX
Public Member Functions | List of all members
openmsx::FileBase Class Referenceabstract

#include <FileBase.hh>

Inheritance diagram for openmsx::FileBase:
Inheritance graph
[legend]

Public Member Functions

virtual ~FileBase ()
 
virtual void read (void *buffer, size_t num)=0
 
virtual void write (const void *buffer, size_t num)=0
 
virtual const bytemmap (size_t &size)
 
virtual void munmap ()
 
virtual size_t getSize ()=0
 
virtual void seek (size_t pos)=0
 
virtual size_t getPos ()=0
 
virtual void truncate (size_t size)
 
virtual void flush ()=0
 
virtual const std::string getURL () const =0
 
virtual const std::string getLocalReference ()
 
virtual const std::string getOriginalName ()
 
virtual bool isReadOnly () const =0
 
virtual time_t getModificationDate ()=0
 

Detailed Description

Definition at line 10 of file FileBase.hh.

Constructor & Destructor Documentation

§ ~FileBase()

openmsx::FileBase::~FileBase ( )
virtual

Definition at line 10 of file FileBase.cc.

References munmap().

Member Function Documentation

§ flush()

virtual void openmsx::FileBase::flush ( )
pure virtual

§ getLocalReference()

const string openmsx::FileBase::getLocalReference ( )
virtual

Reimplemented in openmsx::LocalFile.

Definition at line 51 of file FileBase.cc.

§ getModificationDate()

virtual time_t openmsx::FileBase::getModificationDate ( )
pure virtual

§ getOriginalName()

const string openmsx::FileBase::getOriginalName ( )
virtual

Reimplemented in openmsx::CompressedFileAdapter.

Definition at line 58 of file FileBase.cc.

References openmsx::FileOperations::getFilename(), getURL(), and string_ref::str().

§ getPos()

virtual size_t openmsx::FileBase::getPos ( )
pure virtual

§ getSize()

virtual size_t openmsx::FileBase::getSize ( )
pure virtual

Implemented in openmsx::LocalFile, and openmsx::CompressedFileAdapter.

Referenced by mmap(), and truncate().

§ getURL()

virtual const std::string openmsx::FileBase::getURL ( ) const
pure virtual

§ isReadOnly()

virtual bool openmsx::FileBase::isReadOnly ( ) const
pure virtual

§ mmap()

const byte * openmsx::FileBase::mmap ( size_t &  size)
virtual

§ munmap()

void openmsx::FileBase::munmap ( )
virtual

Reimplemented in openmsx::LocalFile, and openmsx::CompressedFileAdapter.

Definition at line 26 of file FileBase.cc.

References openmsx::MemBuffer< T, ALIGNMENT >::clear().

Referenced by ~FileBase().

§ read()

virtual void openmsx::FileBase::read ( void *  buffer,
size_t  num 
)
pure virtual

Implemented in openmsx::LocalFile, and openmsx::CompressedFileAdapter.

Referenced by mmap().

§ seek()

virtual void openmsx::FileBase::seek ( size_t  pos)
pure virtual

Implemented in openmsx::LocalFile, and openmsx::CompressedFileAdapter.

Referenced by truncate().

§ truncate()

void openmsx::FileBase::truncate ( size_t  size)
virtual

Reimplemented in openmsx::LocalFile, and openmsx::CompressedFileAdapter.

Definition at line 31 of file FileBase.cc.

References getSize(), gl::min(), seek(), and write().

§ write()

virtual void openmsx::FileBase::write ( const void *  buffer,
size_t  num 
)
pure virtual

Implemented in openmsx::LocalFile, and openmsx::CompressedFileAdapter.

Referenced by truncate().


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