Kiwi.Files.DataLibrary Class
Holds a reference to all of the data Files (json, xml, e.t.c) that are accessible on the State that this DataLibrary is on.
Constructor
Kiwi.Files.DataLibrary
(
Kiwi.Files.DataLibrary
-
game
Parameters:
-
game
Kiwi.GameThe game that this DataLibrary belongs to.
Returns:
Methods
add
(
public
-
dataFile
Adds a new data file to the DataLibrary.
Parameters:
-
dataFile
Kiwi.Files.FileThe File that is to be added.
clear
()
public
Resets the Data Library and makes it ready for the next state.
objType
()
String
public
The type of object that this is.
Returns:
String:
"DataLibrary"
rebuild
(
public
-
fileStore
-
state
Rebuild the library from a fileStore. Clears the library and repopulates it.
Parameters:
-
fileStore
Kiwi.Files.FileStoreThe fileStore which is being used
-
state
Kiwi.StateThe State so that we know which DataLibrary to add the files tot.
Properties
data
Object
public
Contains all of the data that this available.