Torque2D Reference

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Types | Public Member Functions | Public Attributes | Friends | List of all members
ResourceObject Class Reference

`#include <resourceManager.h>`

## Public Types
enum | Flags { VolumeBlock = BIT(0), File = BIT(1), Added = BIT(2) }

## Public Member Functions
| ResourceObject ()
| ~ResourceObject ()
void | destruct ()
void | getFileTimes (FileTime *createTime, FileTime *modifyTime)
List Management
ResourceObject * | getNext () const
void | unlink ()
void | linkAfter (ResourceObject *res)

## Public Attributes
S32 | flags
| Set from Flags. More...
StringTableEntry | path
| Resource path. More...
StringTableEntry | name
| Resource name. More...
ResourceInstance * | mInstance
S32 | lockCount
| Lock count; used to control load/unload of resource from memory. More...
U32 | crc
| CRC of resource. More...
Zip::ZipArchive * | mZipArchive
| The zip archive for reading from zips. More...
const Zip::CentralDir * | mCentralDir
| The central directory for this file in the zip. More...
ZIP Archive
If the resource is stored in a zip file, these members are populated.
StringTableEntry | zipPath
| Path of zip file. More...
StringTableEntry | zipName
| Name of zip file. More...
S32 | fileOffset
| Offset of data in zip file. More...
S32 | fileSize
| Size on disk of resource block. More...
S32 | compressedFileSize

## Friends
class | ResDictionary
class | ResManager

## Detailed Description

Wrapper around a ResourceInstance.

This contains all the book-keeping data used by ResDictionary and ResManager.

See also
  ResManager

## Member Enumeration Documentation

enum Flags

Enumerator
VolumeBlock |
File |
Added |

## Constructor & Destructor Documentation

ResourceObject | ( |  | ) |

~ResourceObject | ( |  | ) |
| inline

## Member Function Documentation

void destruct | ( |  | ) |

void getFileTimes | ( | FileTime * | createTime,
|  | FileTime * | modifyTime
| ) |  |

Get some information about file times.

Parameters

  createTime | Pointer to a FileTime structure to fill with information about when this object was created.
  modifyTime | Pointer to a FileTime structure to fill with information about when this object was modified.

ResourceObject* getNext | ( |  | ) | const
| inline

void linkAfter | ( | ResourceObject * | res | ) |
| inline

void unlink | ( |  | ) |
| inline

## Friends And Related Function Documentation

friend class ResDictionary
| friend

friend class ResManager
| friend

## Member Data Documentation

S32 compressedFileSize

Actual size of resource data.

U32 crc

CRC of resource.

S32 fileOffset

Offset of data in zip file.

S32 fileSize

Size on disk of resource block.

S32 flags

Set from Flags.

S32 lockCount

Lock count; used to control load/unload of resource from memory.

const Zip::CentralDir* mCentralDir

The central directory for this file in the zip.

ResourceInstance* mInstance

Pointer to actual object instance. If the object is not loaded, this may be NULL or garbage.

Zip::ZipArchive* mZipArchive

The zip archive for reading from zips.

StringTableEntry name

Resource name.

StringTableEntry path

Resource path.

StringTableEntry zipName

Name of zip file.

StringTableEntry zipPath

Path of zip file.

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

- io/resource/resourceManager.h
- io/resource/resourceManager.cc