BusBoy  2
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Protected Member Functions | List of all members
BUSBOY::ExternalRandomAccessFile Class Reference

#include <ExternalRandomAccessFile.h>

Inheritance diagram for BUSBOY::ExternalRandomAccessFile:
BUSBOY::RandomAccessFile BUSBOY::ExternalRandomAccessFileSinkImpl

Public Member Functions

 ExternalRandomAccessFile (const CExternalRandomAccessFileCallbacks &callbacks)
 
size_t read (char *buf, size_t num)
 Read up to the next num bytes into buf, returns the number of bytes read. More...
 
size_t getLocation ()
 Returns the absolute location of the file pointer, in bytes. More...
 
void setLocation (size_t loc)
 Set absolute location from file start. More...
 
void setLocationFromEnd (size_t loc)
 Set location in bytes back from end of file. More...
 
void skipForward (size_t num)
 Skip num bytes forward from current location. More...
 
void skipBackward (size_t num)
 Skip num bytes backward from current location. More...
 
size_t getFileSize ()
 
void close ()
 
bool isClosed () const
 
 ~ExternalRandomAccessFile ()
 

Protected Member Functions

void assertNotClosed () const
 
std::unique_lock< std::mutex > getLock ()
 
const
CExternalRandomAccessFileCallbacks
getCallbacks () const
 

Constructor & Destructor Documentation

BUSBOY::ExternalRandomAccessFile::ExternalRandomAccessFile ( const CExternalRandomAccessFileCallbacks callbacks)
BUSBOY::ExternalRandomAccessFile::~ExternalRandomAccessFile ( )

Member Function Documentation

void BUSBOY::ExternalRandomAccessFile::assertNotClosed ( ) const
protected
void BUSBOY::ExternalRandomAccessFile::close ( )
virtual
const CExternalRandomAccessFileCallbacks & BUSBOY::ExternalRandomAccessFile::getCallbacks ( ) const
protected
size_t BUSBOY::ExternalRandomAccessFile::getFileSize ( )
virtual
size_t BUSBOY::ExternalRandomAccessFile::getLocation ( )
virtual

Returns the absolute location of the file pointer, in bytes.

Implements BUSBOY::RandomAccessFile.

std::unique_lock< std::mutex > BUSBOY::ExternalRandomAccessFile::getLock ( )
protected
bool BUSBOY::ExternalRandomAccessFile::isClosed ( ) const
virtual
size_t BUSBOY::ExternalRandomAccessFile::read ( char *  buf,
size_t  num 
)
virtual

Read up to the next num bytes into buf, returns the number of bytes read.

Implements BUSBOY::RandomAccessFile.

void BUSBOY::ExternalRandomAccessFile::setLocation ( size_t  loc)
virtual

Set absolute location from file start.

Implements BUSBOY::RandomAccessFile.

void BUSBOY::ExternalRandomAccessFile::setLocationFromEnd ( size_t  loc)
virtual

Set location in bytes back from end of file.

Implements BUSBOY::RandomAccessFile.

void BUSBOY::ExternalRandomAccessFile::skipBackward ( size_t  num)
virtual

Skip num bytes backward from current location.

Implements BUSBOY::RandomAccessFile.

void BUSBOY::ExternalRandomAccessFile::skipForward ( size_t  num)
virtual

Skip num bytes forward from current location.

Implements BUSBOY::RandomAccessFile.


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

Copyright 2014 Google Inc. All rights reserved.