writer

package
v0.0.0-...-ff5f600 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 30, 2016 License: BSD-3-Clause Imports: 10 Imported by: 0

Documentation

Overview

Package writer provides functions for formatting query results.

TODO(ivanpi): Export as VDL formatter library.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WriteCSV

func WriteCSV(out io.Writer, columnNames []string, rs syncbase.ResultStream, delimiter string) error

WriteCSV formats the results as CSV as specified by https://tools.ietf.org/html/rfc4180.

func WriteJson

func WriteJson(out io.Writer, columnNames []string, rs syncbase.ResultStream) error

WriteJson formats the result as a JSON array of arrays (rows) of values.

func WriteTable

func WriteTable(out io.Writer, columnNames []string, rs syncbase.ResultStream) error

WriteTable formats the results as ASCII tables.

Types

type Justification

type Justification int
const (
	Unknown Justification = iota
	Left
	Right
)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL