Dependency for registering objects for persistence with saved games
More...
Dependency for registering objects for persistence with saved games
Attribute: Injectable
◆ DataSubPath()
string pluginbase.Objects.Saves.ISavedGame.DataSubPath |
( |
string |
subpath | ) |
|
Create a subpath within the saved directory folder. Unpreferred method
- Returns
- The sub path.
- Parameters
-
◆ DeletePersistFile()
bool pluginbase.Objects.Saves.ISavedGame.DeletePersistFile |
( |
string |
name, |
|
|
Type |
objType |
|
) |
| |
Deletes a persist file.
- Returns
- Whether a delete occurred
- Parameters
-
name | If set to true name. |
objType | If set to true object type. |
◆ GetPersistentModel< T >() [1/2]
T pluginbase.Objects.Saves.ISavedGame.GetPersistentModel< T > |
( |
string |
name, |
|
|
Func< T > |
newModel |
|
) |
| |
Gets a persistent model, populating it if possible, using a custom constructor
- Returns
- The persistent model.
- Parameters
-
name | Name. |
newModel | New model. |
- Template Parameters
-
◆ GetPersistentModel< T >() [2/2]
T pluginbase.Objects.Saves.ISavedGame.GetPersistentModel< T > |
( |
string |
name | ) |
|
Gets a persistent model, populating it if possible
- Returns
- The persistent model.
- Parameters
-
- Template Parameters
-
◆ RegisterObjectForPersistence() [1/2]
bool pluginbase.Objects.Saves.ISavedGame.RegisterObjectForPersistence |
( |
string |
name, |
|
|
object |
obj |
|
) |
| |
Registers an object for persistence, and populate if possible Uses ///
Attribute: Persist
tag
- Returns
- True if the object was persisted from a file (otherwise false)
- Parameters
-
name | If set to true name. |
obj | If set to true object. |
◆ RegisterObjectForPersistence() [2/2]
bool pluginbase.Objects.Saves.ISavedGame.RegisterObjectForPersistence |
( |
string |
name, |
|
|
IPersistable |
persistable |
|
) |
| |
Registers an IPersistable object for persistence
- Returns
true
, if object for persistence was registered, false
otherwise.
- Parameters
-
name | Name. |
persistable | Persistable. |
The documentation for this interface was generated from the following file: