Versions in this module Expand all Collapse all v0 v0.17.1 Oct 26, 2019 Changes in this version + var BytesDecoder = NewDecoder([]byte{}, BytesDecode) + var ErrClosed = gcerr.Newf(gcerr.FailedPrecondition, nil, "Variable has been Closed") + var New = newVar + var OpenCensusViews = []*view.View + var StringDecoder = NewDecoder("", StringDecode) + func BytesDecode(ctx context.Context, b []byte, obj interface{}) error + func GobDecode(ctx context.Context, data []byte, obj interface{}) error + func JSONDecode(ctx context.Context, data []byte, obj interface{}) error + func StringDecode(ctx context.Context, b []byte, obj interface{}) error + type Decode func(context.Context, []byte, interface{}) error + func DecryptDecode(k *secrets.Keeper, post Decode) Decode + type Decoder struct + func DecoderByName(ctx context.Context, decoderName string, dflt *Decoder) (*Decoder, error) + func NewDecoder(obj interface{}, fn Decode) *Decoder + func (d *Decoder) Decode(ctx context.Context, b []byte) (interface{}, error) + type Snapshot struct + UpdateTime time.Time + Value interface{} + func (s *Snapshot) As(i interface{}) bool + type URLMux struct + func DefaultURLMux() *URLMux + func (mux *URLMux) OpenVariable(ctx context.Context, urlstr string) (*Variable, error) + func (mux *URLMux) OpenVariableURL(ctx context.Context, u *url.URL) (*Variable, error) + func (mux *URLMux) RegisterVariable(scheme string, opener VariableURLOpener) + func (mux *URLMux) ValidVariableScheme(scheme string) bool + func (mux *URLMux) VariableSchemes() []string + type Variable struct + func OpenVariable(ctx context.Context, urlstr string) (*Variable, error) + func (c *Variable) CheckHealth() error + func (c *Variable) Close() error + func (c *Variable) ErrorAs(err error, i interface{}) bool + func (c *Variable) Latest(ctx context.Context) (Snapshot, error) + func (c *Variable) Watch(ctx context.Context) (Snapshot, error) + type VariableURLOpener interface + OpenVariableURL func(ctx context.Context, u *url.URL) (*Variable, error)