StorageManager.d overview
StorageManager
The static class that manages storage for saving game data.
Table of contents
- utils
- StorageManager (class)
- isLocalMode (static method)
- saveObject (static method)
- loadObject (static method)
- objectToJson (static method)
- jsonToObject (static method)
- jsonToZip (static method)
- zipToJson (static method)
- saveZip (static method)
- loadZip (static method)
- exists (static method)
- remove (static method)
- saveToLocalFile (static method)
- loadFromLocalFile (static method)
- localFileExists (static method)
- removeLocalFile (static method)
- saveToForage (static method)
- loadFromForage (static method)
- forageExists (static method)
- removeForage (static method)
- updateForageKeys (static method)
- forageKeysUpdated (static method)
- fsMkdir (static method)
- fsRename (static method)
- fsUnlink (static method)
- fsReadFile (static method)
- fsWriteFile (static method)
- fileDirectoryPath (static method)
- filePath (static method)
- forageKey (static method)
- forageTestKey (static method)
- StorageManager (class)
utils
StorageManager (class)
StorageManager
The static class that manages storage for saving game data.
Signature
export declare class StorageManager {
constructor()
}
isLocalMode (static method)
Signature
static isLocalMode(): boolean
saveObject (static method)
Signature
static saveObject<T>(saveName: string, object: T): Promise<number | void>
loadObject (static method)
Signature
static loadObject<T>(saveName: string): Promise<T>
objectToJson (static method)
Signature
static objectToJson<T>(object: T): Promise<string>
jsonToObject (static method)
Signature
static jsonToObject<T>(json: string): Promise<T>
jsonToZip (static method)
Signature
static jsonToZip(json: string): Promise<string>
zipToJson (static method)
Signature
static zipToJson(zip: string): Promise<string>
saveZip (static method)
Signature
static saveZip(saveName: string, zip: string): Promise<void> | Promise<number>
loadZip (static method)
Signature
static loadZip(saveName: string): Promise<string>
exists (static method)
Signature
static exists(saveName: string): boolean
remove (static method)
Signature
static remove(saveName: string): void | Promise<number>
saveToLocalFile (static method)
Signature
static saveToLocalFile(saveName: string, zip: string): Promise<void>
loadFromLocalFile (static method)
Signature
static loadFromLocalFile(saveName: string): Promise<string>
localFileExists (static method)
Signature
static localFileExists(saveName: string): boolean
removeLocalFile (static method)
Signature
static removeLocalFile(saveName: string): void
saveToForage (static method)
Signature
static saveToForage(saveName: string, zip: string): Promise<number>
loadFromForage (static method)
Signature
static loadFromForage(saveName: string): Promise<string>
forageExists (static method)
Signature
static forageExists(saveName: string): boolean
removeForage (static method)
Signature
static removeForage(saveName: string): Promise<number>
updateForageKeys (static method)
Signature
static updateForageKeys(): Promise<number>
forageKeysUpdated (static method)
Signature
static forageKeysUpdated(): boolean
fsMkdir (static method)
Signature
static fsMkdir(path: string): void
fsRename (static method)
Signature
static fsRename(oldPath: string, newPath: string): void
fsUnlink (static method)
Signature
static fsUnlink(path: string): void
fsReadFile (static method)
Signature
static fsReadFile(path: string): string | null
fsWriteFile (static method)
Signature
static fsWriteFile(path: string, data: string): void
fileDirectoryPath (static method)
Signature
static fileDirectoryPath(): string
filePath (static method)
Signature
static filePath(saveName: string): string
forageKey (static method)
Signature
static forageKey(saveName: string): string
forageTestKey (static method)
Signature
static forageTestKey(): string