Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 1,789 for Writer (0.17 sec)

  1. vendor/github.com/mailru/easyjson/jwriter/writer.go

    )
    
    // Writer is a JSON writer.
    type Writer struct {
    	Flags Flags
    
    	Error        error
    	Buffer       buffer.Buffer
    	NoEscapeHTML bool
    }
    
    // Size returns the size of the data that was written out.
    func (w *Writer) Size() int {
    	return w.Buffer.Size()
    }
    
    // DumpTo outputs the data to given io.Writer, resetting the buffer.
    func (w *Writer) DumpTo(out io.Writer) (written int, err error) {
    Go
    - Registered: 2020-10-07 16:43
    - Last Modified: 2020-04-23 12:43
    - 9.9K bytes
    - Viewed (0)
  2. vendor/github.com/sirupsen/logrus/writer.go

    	"runtime"
    )
    
    func (logger *Logger) Writer() *io.PipeWriter {
    	return logger.WriterLevel(InfoLevel)
    }
    
    func (logger *Logger) WriterLevel(level Level) *io.PipeWriter {
    	return NewEntry(logger).WriterLevel(level)
    }
    
    func (entry *Entry) Writer() *io.PipeWriter {
    	return entry.WriterLevel(InfoLevel)
    }
    
    func (entry *Entry) WriterLevel(level Level) *io.PipeWriter {
    	reader, writer := io.Pipe()
    
    Go
    - Registered: 2020-09-17 01:10
    - Last Modified: 2019-07-24 21:09
    - 1.3K bytes
    - Viewed (0)
  3. js/experimental/runtime/kernel/writer.js

       * @param {!Array<T>} values
       * @param {function(!Writer, T)} valueWriter
       * @template T
       * @private
       */
      writeVariablePacked_(fieldNumber, values, valueWriter) {
        if (values.length === 0) {
          return;
        }
        const writer = new Writer();
        values.forEach(val => valueWriter(writer, val));
        const bytes = writer.getAndResetResultBuffer();
        this.writeDelimited(fieldNumber, bytes);
    JavaScript
    - Registered: 2020-11-25 06:16
    - Last Modified: 2020-05-08 04:53
    - 20.6K bytes
    - Viewed (0)
  4. pkg/csvparser/writer.go

    func NewWriter(w io.Writer) *Writer {
    	return &Writer{
    		Comma:       ',',
    		Quote:       '"',
    		QuoteEscape: '"',
    		w:           bufio.NewWriter(w),
    	}
    }
    
    // Write writes a single CSV record to w along with any necessary quoting.
    // A record is a slice of strings with each string being one field.
    // Writes are buffered, so Flush must eventually be called to ensure
    // that the record is written to the underlying io.Writer.
    Go
    - Registered: 2020-11-29 16:08
    - Last Modified: 2020-04-01 22:39
    - 4.9K bytes
    - Viewed (0)
  5. pkg/s3select/internal/parquet-go/writer.go

    	}
    
    	rowGroup := data.NewRowGroup(chunks, writer.numRows, writer.offset)
    
    	for _, chunk := range chunks {
    		if _, err = writer.writeCloser.Write(chunk.Data()); err != nil {
    			return err
    		}
    
    		writer.offset += chunk.DataLen()
    	}
    
    	writer.footer.RowGroups = append(writer.footer.RowGroups, rowGroup)
    	writer.footer.NumRows += writer.numRows
    
    	writer.numRows = 0
    	writer.columnDataMap = nil
    	return nil
    }
    
    Go
    - Registered: 2020-11-29 16:08
    - Last Modified: 2020-06-25 14:31
    - 4.7K bytes
    - Viewed (0)
  6. common/buf/writer.go

    	return sc.Size, err
    }
    
    // BufferedWriter is a Writer with internal buffer.
    type BufferedWriter struct {
    	sync.Mutex
    	writer   Writer
    	buffer   *Buffer
    	buffered bool
    }
    
    // NewBufferedWriter creates a new BufferedWriter.
    func NewBufferedWriter(writer Writer) *BufferedWriter {
    	return &BufferedWriter{
    		writer:   writer,
    		buffer:   New(),
    		buffered: true,
    	}
    }
    
    Go
    - Registered: 2020-11-25 06:07
    - Last Modified: 2018-12-27 16:00
    - 4.9K bytes
    - Viewed (0)
  7. common/mux/writer.go

    	"v2ray.com/core/common/serial"
    )
    
    type Writer struct {
    	dest         net.Destination
    	writer       buf.Writer
    	id           uint16
    	followup     bool
    	hasError     bool
    	transferType protocol.TransferType
    }
    
    func NewWriter(id uint16, dest net.Destination, writer buf.Writer, transferType protocol.TransferType) *Writer {
    	return &Writer{
    		id:           id,
    		dest:         dest,
    		writer:       writer,
    Go
    - Registered: 2020-11-25 06:07
    - Last Modified: 2018-11-18 19:16
    - 2.6K bytes
    - Viewed (0)
  8. vendor/github.com/hashicorp/go-hclog/writer.go

    package hclog
    
    import (
    	"bytes"
    	"io"
    )
    
    type writer struct {
    	b     bytes.Buffer
    	w     io.Writer
    	color ColorOption
    }
    
    func newWriter(w io.Writer, color ColorOption) *writer {
    	return &writer{w: w, color: color}
    }
    
    func (w *writer) Flush(level Level) (err error) {
    	var unwritten = w.b.Bytes()
    
    	if w.color != ColorOff {
    		color := _levelToColor[level]
    		unwritten = []byte(color.Sprintf("%s", unwritten))
    	}
    Go
    - Registered: 2020-11-25 16:43
    - Last Modified: 2020-02-25 09:33
    - 1.8K bytes
    - Viewed (0)
  9. internal/dbutil/writer.go

    package dbutil
    
    import (
    	"fmt"
    	"io"
    )
    
    // Writer is a wrapper of io.Writer for the gorm.logger.
    type Writer struct {
    	io.Writer
    }
    
    func (w *Writer) Print(v ...interface{}) {
    	if len(v) == 0 {
    		return
    	}
    
    	if len(v) == 1 {
    		fmt.Fprint(w.Writer, v[0])
    		return
    	}
    
    	switch v[0] {
    	case "sql":
    		fmt.Fprintf(w.Writer, "[sql] [%s] [%s] %s %v (%d rows affected)", v[1:]...)
    	case "log":
    Go
    - Registered: 2020-11-19 01:40
    - Last Modified: 2020-04-11 12:18
    - 709 bytes
    - Viewed (0)
  10. reader-writer-lock/src/main/java/com/iluwatar/reader/writer/lock/Writer.java

      /**
       * Create new Writer who writes for 250ms.
       *
       * @param name      - Name of the thread owning the writer
       * @param writeLock - Lock for this writer
       */
      public Writer(String name, Lock writeLock) {
        this(name, writeLock, 250L);
      }
    
      /**
       * Create new Writer.
       *
       * @param name        - Name of the thread owning the writer
       * @param writeLock   - Lock for this writer
    Java
    - Registered: 2020-11-27 18:54
    - Last Modified: 2020-07-30 17:28
    - 2.7K bytes
    - Viewed (0)
Back to top