![]() |
Murl Engine Lua Addon API
Version 1.0 beta
|
The package interface.
Packages operations are processed by a loader thread, the IPackage interface provides methods for controlling and monitoring the package processing.
The IPackage object can be created by the ILoader object.
Get the name of the package.
String GetName()
Get the package's load mode.
Murl.ILoader.LoadMode GetLoadMode()
Get the package's file category.
Murl.IEnums.FileCategory GetFileCategory()
Get the resource package contained in the package.
Murl.Resource.IPackage GetResourcePackage()
Get the logic processor assigned to the package with ILoader::AddPackage().
Murl.SharedPointer.LogicIProcessor GetLogicProcessor()
Check if a logic processor is assigned to the package. This method checks the processor assigned with ILoader::AddPackage() and all processors added by script resources.
Boolean HasLogicProcessor(Murl.SharedPointer.LogicIProcessor logicProcessor)
logicProcessor | The logic processor to check. |
Manually add a graph instance to create when the package is loaded. This only works for packages using ILoader::LOAD_MODE_ON_DEMAND.
Boolean AddGraphInstance(String graphResourceId, String parentNodeId, Integer numberOfReplications)
graphResourceId | The resource ID of the graph to create. |
parentNodeId | The ID of the parent node where to insert the graph. |
numberOfReplications | The number of replications of the graph to create. |
Remove a manually added graph instance. This method is used to remove a graph instance to be created that was previously added via AddGraphInstance(). If it is desired to disable the creation of a graph instance that is statically present in the package, use HideGraphInstance() instead.
Boolean RemoveGraphInstance(String graphResourceId, String parentNodeId)
graphResourceId | The resource ID of the graph to remove from the creation list. |
parentNodeId | The ID of the parent node where to insert the graph. |
Manually remove a graph instance from the creation list, i.e. hide the instance. This only works for packages using ILoader::LOAD_MODE_ON_DEMAND.
Boolean HideGraphInstance(String graphResourceId, String parentNodeId)
graphResourceId | The resource ID of the graph to prevent from being created. |
parentNodeId | The ID of the parent node where the graph would be inserted. |
Unhide a graph instance that was previously hidden via HideGraphInstance().
Boolean UnhideGraphInstance(String graphResourceId, String parentNodeId)
graphResourceId | The resource ID of the graph to unhide. |
parentNodeId | The ID of the parent node where the graph gets inserted. |
Manually add a script instance to create when the package is loaded. This only works for packages using ILoader::LOAD_MODE_ON_DEMAND.
Boolean AddScriptInstance(String scriptResourceId, Integer numberOfReplications)
scriptResourceId | The resource ID of the script to create. |
numberOfReplications | The number of replications of the script to create. |
Remove a manually added script instance. This method is used to remove a script instance to be created that was previously added via AddScriptInstance(). If it is desired to disable the creation of a script instance that is statically present in the package, use HideScriptInstance() instead.
Boolean RemoveScriptInstance(String scriptResourceId)
scriptResourceId | The resource ID of the script to remove from the creation list. |
Manually remove a script instance from the creation list, i.e. hide the instance. This only works for packages using ILoader::LOAD_MODE_ON_DEMAND.
Boolean HideScriptInstance(String scriptResourceId)
scriptResourceId | The resource ID of the script to prevent from being created. |
Unhide a script instance that was previously hidden via HideScriptInstance().
Boolean UnhideScriptInstance(String scriptResourceId)
scriptResourceId | The resource ID of the script to unhide. |
Start loading the package. Calls EnqueueForLoading() if the package is unloaded and not busy loading. Calls CancelUnloading() if the package is busy unloading.
Boolean Load()
Start unloading the package. Calls EnqueueForUnloading() if the package is loaded and not busy unloading. Calls CancelLoading() if the package is busy unloading.
Boolean Unload()
Enqueue the package for loading.
Boolean EnqueueForLoading()
Enqueue the package for unloading.
Boolean EnqueueForUnloading()
Cancel loading the package.
Boolean CancelLoading()
Cancel unloading the package.
Boolean CancelUnloading()
Check if the package is busy. A package is busy during loading or unloading.
Boolean IsBusy()
Check if the package is busy by loading.
Boolean IsBusyLoading()
Check if the package is busy by unloading.
Boolean IsBusyUnloading()
Check if the package is loaded.
Boolean IsLoaded()
Check if the package is unloaded.
Boolean IsUnloaded()
Check if the package failed to load.
Boolean HasFailedLoading()
Check if the package failed to unload.
Boolean HasFailedUnloading()