json

package
v0.8.5 Latest Latest
Warning

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

Go to latest
Published: Dec 29, 2019 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package json provides a JSON presenter that formatting.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Presenter

type Presenter struct{}

Presenter is a presenter that formats v into JSON string.

func NewPresenter

func NewPresenter() *Presenter

func (*Presenter) Format

func (p *Presenter) Format(v interface{}, indent string) (string, error)

Format formats v into JSON string. If indent is not empty, Format indents the output.

Jump to

Keyboard shortcuts

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