scipipe: github.com/scipipe/scipipe/components Index | Files

package components

import "github.com/scipipe/scipipe/components"

Index

Package Files

concatenator.go file_reader.go file_splitter.go maptokeys.go streamtosubstream.go utils.go

func Check Uses

func Check(err error)

Check checks the error err, prints an error message and exits the program

type Concatenator Uses

type Concatenator struct {
    scipipe.BaseProcess
    OutPath string
}

Concatenator is a process that concatenates the content of multiple files received in the in-port In, into one file returned on its out-port, Out

func NewConcatenator Uses

func NewConcatenator(wf *scipipe.Workflow, name string, outPath string) *Concatenator

NewConcatenator returns a new, initialized Concatenator process

func (*Concatenator) In Uses

func (p *Concatenator) In() *scipipe.InPort

In returns the (only) in-port for this process

func (*Concatenator) Out Uses

func (p *Concatenator) Out() *scipipe.OutPort

Out returns the (only) out-port for this process

func (*Concatenator) Run Uses

func (p *Concatenator) Run()

Run runs the Concatenator process

type FileReader Uses

type FileReader struct {
    scipipe.WorkflowProcess

    FilePath *scipipe.ParamInPort
    OutLine  *scipipe.ParamOutPort
    // contains filtered or unexported fields
}

FileReader takes a file path on its FilePath in-port, and returns the file content as []byte on its out-port Out

func NewFileReader Uses

func NewFileReader(wf *scipipe.Workflow, name string) *FileReader

NewFileReader returns an initialized new FileReader

func (*FileReader) Name Uses

func (p *FileReader) Name() string

Name returns the name of the FileReader process

func (*FileReader) ParamInPorts Uses

func (p *FileReader) ParamInPorts() map[string]*scipipe.ParamInPort

ParamInPorts returns all parameter in-ports for the process

func (*FileReader) ParamOutPorts Uses

func (p *FileReader) ParamOutPorts() map[string]*scipipe.ParamOutPort

ParamOutPorts returns all parameter out-ports for the process

func (*FileReader) Run Uses

func (p *FileReader) Run()

Run the FileReader

type FileSplitter Uses

type FileSplitter struct {
    scipipe.EmptyWorkflowProcess

    InFile        *scipipe.InPort
    OutSplitFile  *scipipe.OutPort
    LinesPerSplit int
    // contains filtered or unexported fields
}

FileSplitter is a process that will split a file into multiple files, each with LinesPerSplit number of lines per file

func NewFileSplitter Uses

func NewFileSplitter(wf *scipipe.Workflow, name string, linesPerSplit int) *FileSplitter

NewFileSplitter returns an initialized FileSplitter process that will split a file into multiple files, each with linesPerSplit number of lines per file

func (*FileSplitter) Connected Uses

func (p *FileSplitter) Connected() bool

Connected tells whether all the ports of the FileSplitter process are connected

func (*FileSplitter) InPorts Uses

func (p *FileSplitter) InPorts() map[string]*scipipe.InPort

InPorts returns all the in-ports for the process

func (*FileSplitter) Name Uses

func (p *FileSplitter) Name() string

Name returns the name of the FileSplitter process

func (*FileSplitter) OutPorts Uses

func (p *FileSplitter) OutPorts() map[string]*scipipe.OutPort

OutPorts returns all the out-ports for the process

func (*FileSplitter) Run Uses

func (p *FileSplitter) Run()

Run runs the FileSplitter process

type MapToKeys Uses

type MapToKeys struct {
    scipipe.BaseProcess
    // contains filtered or unexported fields
}

MapToKeys is a process that runs a function provided by the user, upon initialization, that will provide a map of key:value pairs, based in IPs read on the In-port. The key:value pairs (maps) are added to the IPs on the out-port, which are identical to the incoming IPs, except for the new key:value map

func NewMapToKeys Uses

func NewMapToKeys(wf *scipipe.Workflow, name string, mapFunc func(ip *scipipe.IP) map[string]string) *MapToKeys

NewMapToKeys returns an initialized MapToKeys process

func (*MapToKeys) In Uses

func (p *MapToKeys) In() *scipipe.InPort

func (*MapToKeys) Out Uses

func (p *MapToKeys) Out() *scipipe.OutPort

func (*MapToKeys) Run Uses

func (p *MapToKeys) Run()

Run runs the MapToKeys process

type StreamToSubStream Uses

type StreamToSubStream struct {
    scipipe.EmptyWorkflowProcess

    In           *scipipe.InPort
    OutSubStream *scipipe.OutPort
    // contains filtered or unexported fields
}

StreamToSubStream takes a normal stream of IP's representing individual files, and returns one IP where the incoming IPs are sent on its substream.

func NewStreamToSubStream Uses

func NewStreamToSubStream(wf *scipipe.Workflow, name string) *StreamToSubStream

NewStreamToSubStream instantiates a new StreamToSubStream process

func (*StreamToSubStream) Connected Uses

func (p *StreamToSubStream) Connected() bool

Connected tells whether all the ports of the process are connected

func (*StreamToSubStream) InPorts Uses

func (p *StreamToSubStream) InPorts() map[string]*scipipe.InPort

InPorts returns all the in-ports for the process

func (*StreamToSubStream) Name Uses

func (p *StreamToSubStream) Name() string

Name returns the name of the StreamToSubStream process

func (*StreamToSubStream) OutPorts Uses

func (p *StreamToSubStream) OutPorts() map[string]*scipipe.OutPort

OutPorts returns all the out-ports for the process

func (*StreamToSubStream) Run Uses

func (p *StreamToSubStream) Run()

Run runs the StreamToSubStream

Package components imports 7 packages (graph). Updated 2018-02-19. Refresh now. Tools for package owners.