# Visualization Library

A lightweight C++ OpenGL middleware for 2D/3D graphics

[Home] [Tutorials] [All Classes] [Grouped Classes]

# vl::DiskFile Class Reference

A VirtualFile that operates on regular disk files. More...

`#include <DiskFile.hpp>`

Inheritance diagram for vl::DiskFile:

List of all members.

## Public Member Functions

| DiskFile (const String &path=String())
| ~DiskFile ()
virtual const char * | className ()
| Returns the name of the class.
bool | open (const String &path, EOpenMode mode)
| The specified path is relative to the parent directory. See setPhysicalPath().
virtual bool | open (EOpenMode mode)
virtual bool | isOpen () const
virtual void | close ()
virtual long long | size () const
| Returns the file size in bytes or -1 on error.
virtual bool | exists () const
DiskFile & | operator= (const DiskFile &other)
virtual ref< VirtualFile > | clone () const

## Protected Member Functions

| DiskFile (const DiskFile &other)
virtual long long | read_Implementation (void *buffer, long long byte_count)
virtual long long | write_Implementation (const void *buffer, long long byte_count)
virtual long long | position_Implementation () const
virtual bool | seekSet_Implementation (long long offset)
ref< DiskDirectory > | parentDir () const

## Protected Attributes

FILE * | mHandle

## Friends

class | DiskDirectory

## Detailed Description

A VirtualFile that operates on regular disk files.

See also:
  - VirtualDirectory
  - DiskDirectory
  - MemoryDirectory
  - ZippedDirectory
  - FileSystem
  - VirtualFile
  - MemoryFile
  - ZippedFile

## Constructor & Destructor Documentation

vl::DiskFile::DiskFile | ( | const DiskFile & | other | ) | `[inline, protected]`

DiskFile::DiskFile | ( | const String & | path = `String()` | ) |

DiskFile::~DiskFile | ( |  | ) |

## Member Function Documentation

virtual const char* vl::DiskFile::className | ( |  | ) | `[inline, virtual]`

Returns the name of the class.

Reimplemented from vl::VirtualFile.

bool DiskFile::open | ( | const String & | path,
|  | EOpenMode | mode |
| ) |  |  |

The specified path is relative to the parent directory. See setPhysicalPath().

bool DiskFile::open | ( | EOpenMode | mode | ) | `[virtual]`

Implements vl::VirtualFile.

bool DiskFile::isOpen | ( |  | ) | const`[virtual]`

Implements vl::VirtualFile.

void DiskFile::close | ( |  | ) | `[virtual]`

Implements vl::VirtualFile.

long long DiskFile::size | ( |  | ) | const`[virtual]`

Returns the file size in bytes or -1 on error.

Implements vl::VirtualFile.

bool DiskFile::exists | ( |  | ) | const`[virtual]`

Implements vl::VirtualFile.

DiskFile& vl::DiskFile::operator= | ( | const DiskFile & | other | ) | `[inline]`

ref< VirtualFile > DiskFile::clone | ( |  | ) | const`[virtual]`

Implements vl::VirtualFile.

long long DiskFile::read_Implementation | ( | void * | buffer,
|  | long long | byte_count |
| ) |  |  | `[protected, virtual]`

Implements vl::VirtualFile.

long long DiskFile::write_Implementation | ( | const void * | buffer,
|  | long long | byte_count |
| ) |  |  | `[protected, virtual]`

Implements vl::VirtualFile.

long long DiskFile::position_Implementation | ( |  | ) | const`[protected, virtual]`

Implements vl::VirtualFile.

bool DiskFile::seekSet_Implementation | ( | long long | offset | ) | `[protected, virtual]`

Implements vl::VirtualFile.

ref<DiskDirectory> vl::DiskFile::parentDir | ( |  | ) | const`[protected]`

## Friends And Related Function Documentation

friend class DiskDirectory`[friend]`

## Member Data Documentation

FILE* vl::DiskFile::mHandle`[protected]`

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

- E:/VisualizationLibrary/BuildSystem/VL_DISTRO/Visualization_Library_SDK/src/vl/DiskFile.hpp
- E:/VisualizationLibrary/BuildSystem/VL_DISTRO/Visualization_Library_SDK/src/vl/DiskFile.cpp

Visualization Library v2009.07 Reference Documentation
Copyright 2005-2009 Michele Bosi. All rights reserved.
Updated on Mon Aug 10 21:41:34 2009.
Permission is granted to use this page to write and publish articles regarding Visualization Library.