Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type FileProcessor ¶
type FileProcessor struct {
SplitCnt int
Seq bool
PrefixTime bool
FileWrapper
// contains filtered or unexported fields
}
func NewFileProcessor ¶
func NewFileProcessor(num, maxSize, splitCnt int, seq, prefixTime bool, m Mapper, r Reducer, fw FileWrapper) *FileProcessor
func (*FileProcessor) ProcFile ¶
func (p *FileProcessor) ProcFile(path, dir, ext string) error
func (*FileProcessor) ProcPath ¶
func (p *FileProcessor) ProcPath(path, dir, ext string) error
func (*FileProcessor) ProcPathReverse ¶
func (p *FileProcessor) ProcPathReverse(path, dir, ext string) error
type FileWrapper ¶
func DummyWrapper ¶
func DummyWrapper() FileWrapper
type FileWriter ¶
func NewFileWriter ¶
func NewFileWriter(fw FileWrapper, dir, fn, ext string, splitCnt int) FileWriter
func WithSequence ¶
func WithSequence(parent FileWriter) FileWriter
WithSequence keep output follow input sequence
type LineInfoSlice ¶
type LineInfoSlice []lineInfo
func (LineInfoSlice) Len ¶
func (lis LineInfoSlice) Len() int
func (LineInfoSlice) Swap ¶
func (lis LineInfoSlice) Swap(i, j int)
type TermWriter ¶
type TermWriter struct {
FileWrapper
}
func NewTermWriter ¶
func NewTermWriter(fw FileWrapper) *TermWriter
func (*TermWriter) Close ¶
func (w *TermWriter) Close() error
func (*TermWriter) Open ¶
func (w *TermWriter) Open() error
func (*TermWriter) Write ¶
func (w *TermWriter) Write(li lineInfo) (int, error)
Click to show internal directories.
Click to hide internal directories.