class SystemDAG
SystemDAG
()
|
Signature
constructor() Returns |
addSystem
(
system
, priorityGroup
)
|
Adds a system to the dependency graph.
This method:
Signature
fun addSystem(system: SystemBase, priorityGroup: PriorityGroup = PriorityGroup.NORMAL) Parameters Throws
IllegalArgumentException
|
findSystem
(
clazz
)
|
Finds a system in the dependency graph. Throws an exception if the system is not found.
Signature
fun <T : SystemBase> findSystem(clazz: KClass<T>): T Parameters
clazz:
KClass
Throws
Exception
|
getEarlySystems
()
|
Gets the list of early systems that runs before all other systems.
Signature
fun getEarlySystems(): List<SystemBase> Returns
List
|
getLateSystems
()
|
Gets the list of late systems that runs after all other systems.
Signature
fun getLateSystems(): List<SystemBase> Returns
List
|
getUnorderedLateExecuteSystems
()
|
Gets the list of all systems that implement LateExecuteSystem that have been added to the DAG. The order of the systems is NOT guaranteed.
Signature
fun getUnorderedLateExecuteSystems(): List<SystemBaseWithLateExecute> Returns
List
|
removeSystem
(
clazz
)
|
Removes a system from the dependency graph.
Signature
fun <T : SystemBase> removeSystem(clazz: KClass<T>): Boolean Parameters
clazz:
KClass
Returns
Boolean
|
removeSystem
()
|
Removes a system from the dependency graph using reified type parameter.
Signature
inline fun <T : SystemBase> removeSystem(): Boolean Returns
Boolean
|
setEarlySystems
(
earlySystems
)
|
Sets the list of early systems that runs before all other systems.
Signature
fun setEarlySystems(earlySystems: List<SystemBase>) Parameters
earlySystems:
List
Throws
RuntimeException
|
setLateSystems
(
lateSystems
)
|
Sets the list of late systems that runs after all other systems.
Signature
fun setLateSystems(lateSystems: List<SystemBase>) Parameters
lateSystems:
List
Throws
RuntimeException
|
topologicalSortWithCycleDetection
()
|
Performs a topological sort of the systems based on their dependencies.
This method:
Signature
fun topologicalSortWithCycleDetection(): MutableList<SystemBase> Returns
MutableList
Throws
RuntimeException
|
tryFindSystem
(
clazz
)
|
Attempts to find a system in the dependency graph.
Signature
fun <T : SystemBase> tryFindSystem(clazz: KClass<T>): T? Parameters
clazz:
KClass
|