All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.apache.tinkerpop.gremlin.ogm.paths.bound.BoundPath.kt Maven / Gradle / Ivy

There is a newer version: 0.21.0
Show newest version
package org.apache.tinkerpop.gremlin.ogm.paths.bound

import org.apache.tinkerpop.gremlin.ogm.elements.Vertex
import org.apache.tinkerpop.gremlin.ogm.paths.Path

/**
 * A [BoundPath] encapsulates a [Path] plus the [FROM] objects to start the path's traversal with
 */
interface BoundPath {

    /**
     * The objects to start traversing [path] with.
     */
    val froms: Iterable

    /**
     * A path through the graph to traverse through using the [from] objects
     */
    val path: Path

    /**
     * A [BoundPath] that results to a optional or non-optional (aka single) object
     * for each [from] object that the path is traversed with.
     */
    interface ToOne : BoundPath

    /**
     * A [BoundPath] that results to 0 or more objects for each [from] object that
     * the traversed path starts with.
     */
    interface ToMany : BoundPath {

        override val path: Path.ToMany
    }

    /**
     * A [BoundPath] that results to a non-optional object
     * for each [from] object that the path is traversed with.
     */
    interface ToSingle : ToOne {

        override val path: Path.ToSingle
    }

    /**
     * A [BoundPath] that results to an optional object
     * for each [from] object that the path is traversed with.
     */
    interface ToOptional : ToOne {

        override val path: Path.ToOptional
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy