com.zepben.evolve.services.network.tracing.connectivity.ConnectedEquipmentTraversal.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of evolve-sdk Show documentation
Show all versions of evolve-sdk Show documentation
SDK for interaction with the evolve platform
/*
* Copyright 2022 Zeppelin Bend Pty Ltd
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
package com.zepben.evolve.services.network.tracing.connectivity
import com.zepben.evolve.cim.iec61970.base.core.ConductingEquipment
import com.zepben.evolve.services.network.tracing.traversals.BasicTraversal
import com.zepben.evolve.services.network.tracing.traversals.Tracker
import com.zepben.evolve.services.network.tracing.traversals.TraversalQueue
/**
* Traversal of [ConductingEquipmentStep] which wraps [BasicTraversal] for the purposes of starting directly from [ConductingEquipment].
*/
class ConnectedEquipmentTraversal(
queueNext: QueueNext,
queue: TraversalQueue,
tracker: Tracker
) : BasicTraversal(queueNext, queue, tracker) {
/**
* Helper function to start the traversal from a [ConductingEquipment] without needing to explicitly creating the [ConductingEquipmentStep].
*
* @param conductingEquipment THe [ConductingEquipment] to start from.
*/
@JvmOverloads
fun run(conductingEquipment: ConductingEquipment, canStopOnStartItem: Boolean = true): Unit =
run(ConductingEquipmentStep(conductingEquipment), canStopOnStartItem)
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy