Documentation
¶
Index ¶
- func Buffer2Struct(buf *bytes.Buffer, i interface{}) error
- func GetFirebase() *firebase.App
- func GetToday() time.Time
- func IndexOf(values []string, value string) int
- func IndexOfWithField(values interface{}, value interface{}, key string) int
- func IndexOfWithFunction(values interface{}, value interface{}, ...) int
- func InitFirebase(credentialsFile string) error
- func LoadConfig(filename string, doc interface{}) error
- func Map2Struct(v map[string]interface{}, i interface{}) error
- func NewInstance(t reflect.Type) interface{}
- func Now() *time.Time
- func SetInterval(callback func(), interval time.Duration, async bool) chan bool
- func SetTimeout(callback func(), milliseconds int)
- func Struct2Map(v interface{}) (map[string]interface{}, error)
- func TypeOf(i interface{}) reflect.Type
- func WriteConfig(filename string, doc interface{}) error
- type Auth
- type Emitter
- type Error
- type IDTokenResp
- type SMTP
- type SMTPConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Buffer2Struct ¶
Parse a buffer to an interface
func GetFirebase ¶
func IndexOfWithField ¶ added in v0.2.8
func IndexOfWithFunction ¶ added in v0.2.8
func InitFirebase ¶
func LoadConfig ¶
Load yaml from a file to a struct
func Map2Struct ¶
From map to struct using json.Marshal() and json json.Unmarshal()
func NewInstance ¶
func SetTimeout ¶
func SetTimeout(callback func(), milliseconds int)
func Struct2Map ¶
From struct to map[string]interface{} using json.Marshal() and json json.Unmarshal()
Types ¶
type Error ¶ added in v0.2.11
type Error struct {
// contains filtered or unexported fields
}
add code into error
type IDTokenResp ¶
type IDTokenResp struct { Token string `json:"idToken"` RefreshToken string `json:"refreshToken"` IsNewUser bool `json:"isNewUser"` }
func GetFirebaseIDToken ¶
func GetFirebaseIDToken(apiKey, customToken string) (*IDTokenResp, error)
Click to show internal directories.
Click to hide internal directories.