trending

package
v0.0.0-...-6d7d60d Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2018 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Deamon

type Deamon struct {
	// contains filtered or unexported fields
}

func StartDeamon

func StartDeamon() *Deamon

StartDeamon return a deamon server.

func (*Deamon) Get

func (d *Deamon) Get(key, field string) (string, error)

Get is a thin wrapper around Storage.HGet().

func (*Deamon) GetJSON

func (d *Deamon) GetJSON(key, field string, v interface{}) error

GetJSON gets the JSON-encoded data, parses it and stores the result in the value pointed to by v.

func (*Deamon) InitStorage

func (d *Deamon) InitStorage()

InitStorage initializes storage. trying to get a key that doesn't exist will make an error in Redis package.

func (*Deamon) Refrech

func (d *Deamon) Refrech()

Refrech notices UpdateDeamon to refrech the data.

func (*Deamon) Set

func (d *Deamon) Set(key, field, value string) (bool, error)

Set is a thin wrapper around Storage.HSet().

func (*Deamon) UpdateDaemon

func (d *Deamon) UpdateDaemon(tickDuration time.Duration)

UpdateDaemon represents a update deamon server.

Jump to

Keyboard shortcuts

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