Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ChanSource ¶
type ChanSource struct {
// contains filtered or unexported fields
}
ChanSource is a source that returns a channel of data.
func NewChanSource ¶
func NewChanSource(out chan any) *ChanSource
NewChanSource returns a new ChanSource.
func (*ChanSource) Pipe ¶
func (s *ChanSource) Pipe(c streams.Operatable) streams.Operatable
Pipe pipes the output channel to the input channel.
type ElementReader ¶
ElementReader is a function that reads an element from an io.Reader.
type ReaderSource ¶
type ReaderSource struct {
// contains filtered or unexported fields
}
ReaderSource is a source connector that reads elements from an io.Reader.
func NewReaderSource ¶
func NewReaderSource(reader io.ReadCloser, elementReader ElementReader) (*ReaderSource, error)
NewReaderSource returns a new ReaderSource connector that reads elements from.
func (*ReaderSource) Out ¶
func (s *ReaderSource) Out() <-chan any
Out returns the output channel of the ReaderSource connector.
func (*ReaderSource) Pipe ¶
func (s *ReaderSource) Pipe(operator streams.Operatable) streams.Operatable
Pipe pipes the output channel of the ReaderSource connector to the input channel.
type SeqSource ¶ added in v0.4.1
type SeqSource[I any] struct { // contains filtered or unexported fields }
SeqSource is a source that iterates over an iterable.
func NewSeqSource ¶ added in v0.4.1
NewSeqSource returns a new SeqSource.
func (*SeqSource[I]) Out ¶ added in v0.4.1
Out returns the output channel of the ReaderSource connector.
func (*SeqSource[I]) Pipe ¶ added in v0.4.1
func (s *SeqSource[I]) Pipe(operator streams.Operatable) streams.Operatable
Pipe pipes the output channel of the ReaderSource connector to the input channel.