types

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Jan 17, 2017 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Any

type Any json.RawMessage

Any is the raw configuration for the plugin

func AnyBytes

func AnyBytes(data []byte) *Any

AnyBytes returns an Any from the encoded message bytes

func AnyString

func AnyString(s string) *Any

AnyString returns an Any from a string that represents the marshaled/encoded data

func AnyValue

func AnyValue(v interface{}) (*Any, error)

AnyValue returns an Any from a value by marshaling / encoding the input

func AnyValueMust

func AnyValueMust(v interface{}) *Any

AnyValueMust returns an Any from a value by marshaling / encoding the input. It panics if there's error.

func (*Any) Bytes

func (c *Any) Bytes() []byte

Bytes returns the encoded bytes

func (*Any) Decode

func (c *Any) Decode(typed interface{}) error

Decode decodes the any into the input typed struct

func (*Any) MarshalJSON

func (c *Any) MarshalJSON() ([]byte, error)

MarshalJSON implements the json Marshaler interface

func (*Any) String

func (c *Any) String() string

String returns the string representation.

func (*Any) UnmarshalJSON

func (c *Any) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json Unmarshaler interface

Jump to

Keyboard shortcuts

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