json

package
v0.0.0-...-91b1b85 Latest Latest
Warning

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

Go to latest
Published: Dec 6, 2016 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

The oryx json package support json with c++ style comments. User can use the following APIs:

Unmarshal, directly unmarshal a Reader to object, like json.Unmarshal
NewJsonPlusReader, convert the Reader to data stream without comments.
NewCommentReader, specified the special comment or tags.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewCommentReader

func NewCommentReader(r io.Reader, startMatches, endMatches [][]byte, isComments, requiredMatches []bool) io.Reader

the reader to ignore specified comments or tags.

func NewJsonPlusReader

func NewJsonPlusReader(r io.Reader) io.Reader

the reader support c++-style comment,

block: /* comments */
line: // comments

to filter the comment and got pure raw data.

func Unmarshal

func Unmarshal(r io.Reader, v interface{}) (err error)

user can directly use this to UnMarshal a json stream.

Types

This section is empty.

Jump to

Keyboard shortcuts

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