public interface Pipe
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close the pipe.
|
void |
close(Exception e)
Close the pipe (see close()) and record
e as its termination
status. |
Domain |
get()
Answer the next element if there is one, otherwise throw a NoSuchElementException.
|
boolean |
hasNext()
Answer true iff there are more elements for
get() to get. |
void |
put(Domain d)
Put a domain element into the pipe for later extraction.
|
boolean hasNext()
get() to get. If
the pipe was closed with an exception, throw that exception.Domain get()
void put(Domain d)
void close()
false, and
get will throw an exception.void close(Exception e)
e as its termination
status. Any get from the pipe must then fail, throwing an
exception.e - the exception that caused the pipe to be closedLicenced under the Apache License, Version 2.0