public class Bindings extends Object implements Iterable<Bindings.Binding>
null
bindings
for a Statement
using BindMarkers
.
Bindings are typically immutable.Modifier and Type | Class and Description |
---|---|
static class |
Bindings.Binding
Base class for value objects representing a value or a
NULL binding. |
Constructor and Description |
---|
Bindings()
Create empty
Bindings . |
Bindings(Collection<Bindings.Binding> bindings)
Create
Bindings from the given collection. |
Modifier and Type | Method and Description |
---|---|
Bindings |
and(Bindings other)
|
void |
apply(BindTarget bindTarget)
Apply the bindings to a
BindTarget . |
static Bindings |
empty()
Return an empty
Bindings object. |
void |
forEach(Consumer<? super Bindings.Binding> action)
Perform the given action for each binding of this
Bindings until all
bindings have been processed or the action throws an exception. |
protected Map<BindMarker,Bindings.Binding> |
getBindings() |
Iterator<Bindings.Binding> |
iterator() |
static Bindings |
merge(Bindings left,
Bindings right)
|
Spliterator<Bindings.Binding> |
spliterator() |
public Bindings()
Bindings
.public Bindings(Collection<Bindings.Binding> bindings)
Bindings
from the given collection.bindings
- a collection of Bindings.Binding
objectsprotected Map<BindMarker,Bindings.Binding> getBindings()
public Bindings and(Bindings other)
other
- the object to merge withBindings
objectpublic void apply(BindTarget bindTarget)
BindTarget
.bindTarget
- the target to apply bindings topublic void forEach(Consumer<? super Bindings.Binding> action)
Bindings
until all
bindings have been processed or the action throws an exception. Actions are
performed in the order of iteration (if an iteration order is specified).
Exceptions thrown by the action are relayed to theforEach
in interface Iterable<Bindings.Binding>
action
- the action to be performed for each Bindings.Binding
public Iterator<Bindings.Binding> iterator()
iterator
in interface Iterable<Bindings.Binding>
public Spliterator<Bindings.Binding> spliterator()
spliterator
in interface Iterable<Bindings.Binding>