ZenLib

- Main Page
- Related Pages
- Namespaces
- Classes
- Files

- Class List
- Class Hierarchy
- Class Members

Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
ZenLib::File Class Reference

File manipulation. More...

`#include <File.h>`

## Public Types
enum | access_t { Access_Read = 0, Access_Write = 1, Access_Read_Write = 2, Access_Write_Append = 3, Access_Write_Excluding = 4 }
| Options for Open method. More...
enum | move_t { FromBegin = 0, FromCurrent = 1, FromEnd = 2 }
| Options for Move method. More...

## Public Member Functions
| File ()
| File (ZenLib::Ztring File_Name, access_t Access=Access_Read)
| ~File ()
bool | Open (const tstring &File_Name, access_t Access=Access_Read)
bool | Create (const ZenLib::Ztring &File_Name, bool OverWrite=true)
void | Close ()
size_t | Read (int8u *Buffer, size_t Buffer_Size)
size_t | Write (const int8u *Buffer, size_t Buffer_Size)
size_t | Write (const Ztring &ToWrite)
bool | Truncate (int64u Offset=(int64u)-1)
bool | GoTo (int64s Position, move_t MoveMethod=FromBegin)
int64u | Position_Get ()
int64u | Size_Get ()
Ztring | Created_Get ()
Ztring | Created_Local_Get ()
Ztring | Modified_Get ()
Ztring | Modified_Local_Get ()
bool | Opened_Get ()

## Static Public Member Functions
static int64u | Size_Get (const Ztring &File_Name)
static Ztring | Created_Get (const Ztring &File_Name)
static Ztring | Modified_Get (const Ztring &File_Name)
static bool | Exists (const Ztring &File_Name)
static bool | Copy (const Ztring &Source, const Ztring &Destination, bool OverWrite=false)
static bool | Move (const Ztring &Source, const Ztring &Destination, bool OverWrite=false)
static bool | Delete (const Ztring &File_Name)

## Public Attributes
Ztring | File_Name
int64u | Position
int64u | Size
void * | File_Handle

## Detailed Description

File manipulation.

## Member Enumeration Documentation

enum ZenLib::File::access_t

Options for Open method.

Enumerator
Access_Read | Read permission.
Access_Write | Write permission.
Access_Read_Write | Read and Write permissions.
Access_Write_Append | Write permission without deleting old file.
Access_Write_Excluding | Write permission preventing reading.

enum ZenLib::File::move_t

Options for Move method.

Enumerator
FromBegin | Begin of file.
FromCurrent | Current position.
FromEnd | End of file.

## Constructor & Destructor Documentation

ZenLib::File::File | ( |  | ) |

ZenLib::File::File | ( | ZenLib::Ztring | File_Name,
|  | access_t | Access = `Access_Read`
| ) |  |

ZenLib::File::~File | ( |  | ) |

## Member Function Documentation

void ZenLib::File::Close | ( |  | ) |

static bool ZenLib::File::Copy | ( | const Ztring & | Source,
|  | const Ztring & | Destination,
|  | bool | OverWrite = `false`
| ) |  |
| static

bool ZenLib::File::Create | ( | const ZenLib::Ztring & | File_Name,
|  | bool | OverWrite = `true`
| ) |  |

Ztring ZenLib::File::Created_Get | ( |  | ) |

static Ztring ZenLib::File::Created_Get | ( | const Ztring & | File_Name | ) |
| static

Ztring ZenLib::File::Created_Local_Get | ( |  | ) |

static bool ZenLib::File::Delete | ( | const Ztring & | File_Name | ) |
| static

static bool ZenLib::File::Exists | ( | const Ztring & | File_Name | ) |
| static

bool ZenLib::File::GoTo | ( | int64s | Position,
|  | move_t | MoveMethod = `FromBegin`
| ) |  |

Ztring ZenLib::File::Modified_Get | ( |  | ) |

static Ztring ZenLib::File::Modified_Get | ( | const Ztring & | File_Name | ) |
| static

Ztring ZenLib::File::Modified_Local_Get | ( |  | ) |

static bool ZenLib::File::Move | ( | const Ztring & | Source,
|  | const Ztring & | Destination,
|  | bool | OverWrite = `false`
| ) |  |
| static

bool ZenLib::File::Open | ( | const tstring & | File_Name,
|  | access_t | Access = `Access_Read`
| ) |  |

bool ZenLib::File::Opened_Get | ( |  | ) |

int64u ZenLib::File::Position_Get | ( |  | ) |

size_t ZenLib::File::Read | ( | int8u * | Buffer,
|  | size_t | Buffer_Size
| ) |  |

int64u ZenLib::File::Size_Get | ( |  | ) |

static int64u ZenLib::File::Size_Get | ( | const Ztring & | File_Name | ) |
| static

bool ZenLib::File::Truncate | ( | int64u | Offset = `(int64u)-1` | ) |

size_t ZenLib::File::Write | ( | const int8u * | Buffer,
|  | size_t | Buffer_Size
| ) |  |

size_t ZenLib::File::Write | ( | const Ztring & | ToWrite | ) |

## Member Data Documentation

void* ZenLib::File::File_Handle

Ztring ZenLib::File::File_Name

int64u ZenLib::File::Position

int64u ZenLib::File::Size

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

- File.h