java.lang.Object
swim.streamlet.AbstractOutlet<O>
- All Implemented Interfaces:
Outlet<O>
- Direct Known Subclasses:
AndOutlet
,BinaryOutlet
,ConditionalOutlet
,GetOutlet
,InvokeOutlet
,KeyOutlet
,OrOutlet
,StreamletOutlet
,UnaryOutlet
,ValueInput
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
bindOutput
(Inlet<? super O> output) Adds anoutput
to the set ofInlet
s that depend on the state of thisOutlet
.void
Marks thisOutlet
—and alloutputs
that depend on the state of thisOutlet
—as having decoherent state.protected void
protected void
didRecohereInput
(int version) void
Disconnects allInlet
s dominated by thisOutlet
in the dataflow dependency graph.void
Disconnects allOutlet
s dominated by thisOutlet
in the dataflow graph.abstract O
get()
Returns the current state of thisOutlet
.protected void
protected void
onRecohereInput
(int version) Returns anIterator
over the set ofInlet
s that depend on the state of thisOutlet
.void
recohereInput
(int version) Updates the state of thisOutlet
to make it consistent with the targetversion
.void
unbindOutput
(Inlet<? super O> output) Removes anoutput
from the set ofInlet
s that depend on the state of thisOutlet
.void
Disconnects all outputs from thisOutlet
by invokingInlet.unbindInput()
on eachInelt
that depends on the state of thisOutlet
.protected void
protected void
willRecohereInput
(int version)
-
Field Details
-
outputs
-
version
protected int version
-
-
Constructor Details
-
AbstractOutlet
public AbstractOutlet()
-
-
Method Details
-
get
Description copied from interface:Outlet
Returns the current state of thisOutlet
. -
outputIterator
Description copied from interface:Outlet
Returns anIterator
over the set ofInlet
s that depend on the state of thisOutlet
.- Specified by:
outputIterator
in interfaceOutlet<O>
-
bindOutput
Description copied from interface:Outlet
Adds anoutput
to the set ofInlet
s that depend on the state of thisOutlet
. Theoutput
will be decohered when the state of thisOutlet
is decohered, and recohered when thisOutlet
is recohered.- Specified by:
bindOutput
in interfaceOutlet<O>
-
unbindOutput
Description copied from interface:Outlet
Removes anoutput
from the set ofInlet
s that depend on the state of thisOutlet
.- Specified by:
unbindOutput
in interfaceOutlet<O>
-
unbindOutputs
public void unbindOutputs()Description copied from interface:Outlet
Disconnects all outputs from thisOutlet
by invokingInlet.unbindInput()
on eachInelt
that depends on the state of thisOutlet
.- Specified by:
unbindOutputs
in interfaceOutlet<O>
-
disconnectOutputs
public void disconnectOutputs()Description copied from interface:Outlet
Disconnects allOutlet
s dominated by thisOutlet
in the dataflow graph. Used to recursively clean up chains of combinators originating from thisInlet
.- Specified by:
disconnectOutputs
in interfaceOutlet<O>
-
disconnectInputs
public void disconnectInputs()Description copied from interface:Outlet
Disconnects allInlet
s dominated by thisOutlet
in the dataflow dependency graph. Used to recursively clean up chains of combinators passing through thisOutlet
.- Specified by:
disconnectInputs
in interfaceOutlet<O>
-
decohereInput
public void decohereInput()Description copied from interface:Outlet
Marks thisOutlet
—and alloutputs
that depend on the state of thisOutlet
—as having decoherent state.- Specified by:
decohereInput
in interfaceOutlet<O>
-
recohereInput
public void recohereInput(int version) Description copied from interface:Outlet
Updates the state of thisOutlet
to make it consistent with the targetversion
. TheOutlet
only needs to update if its currentversion
differs from the targetversion
. To update its state, theOutlet
first invokesStreamlet.recohere(int)
on theStreamlet
to which it's attached. It then invokesInlet.recohereOutput(int)
on each of its dependentoutputs
.- Specified by:
recohereInput
in interfaceOutlet<O>
-
willDecohereInput
protected void willDecohereInput() -
onDecohereInput
protected void onDecohereInput() -
didDecohereInput
protected void didDecohereInput() -
willRecohereInput
protected void willRecohereInput(int version) -
onRecohereInput
protected void onRecohereInput(int version) -
didRecohereInput
protected void didRecohereInput(int version)
-