Package com.google.adk.workflow
Record Class Edge
java.lang.Object
java.lang.Record
com.google.adk.workflow.Edge
- Record Components:
from- The node whose completion fires this edge.to- The node this edge triggers.routes- The routes that select this edge. An empty list makes the edge unconditional.
@Experimental
public record Edge(Node from, Node to, com.google.common.collect.ImmutableList<Route> routes)
extends Record
A connection between two nodes in a workflow graph. An edge with no routes fires whenever its
source completes; any other edge fires only when one of its routes is selected, as
Route
describes.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.from()Returns the value of thefromrecord component.final inthashCode()Returns a hash code value for this object.booleanReturnstrueif this edge fires regardless of the routes its source emits.com.google.common.collect.ImmutableList<Route>routes()Returns the value of theroutesrecord component.to()Returns the value of thetorecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Method Details
-
isUnconditional
public boolean isUnconditional()Returnstrueif this edge fires regardless of the routes its source emits. -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
from
Returns the value of thefromrecord component.- Returns:
- the value of the
fromrecord component
-
to
Returns the value of thetorecord component.- Returns:
- the value of the
torecord component
-
routes
Returns the value of theroutesrecord component.- Returns:
- the value of the
routesrecord component
-