models

package
v0.0.0-...-a7681e9 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2015 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DbName          = "qr-server"
	KeySetModelName = "keyset"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type KeySet

type KeySet struct {
	LastEditTime time.Time `json:"lastedit_time"`
	DateCreated  time.Time `json:"date_created"`
	PublicKey    string    `json:"public_key"`
	PrivateKey   string    `json:"private_key"`
	// contains filtered or unexported fields
}

func (*KeySet) Init

func (ks *KeySet) Init()

func (*KeySet) PreSave

func (ks *KeySet) PreSave()

type Lease

type Lease struct {
	Duration     int64
	AuthorizerId bson.ObjectId
	CreationDate time.Time
	PrivateKey   string
	PublicKey    string
}

func (*Lease) Expired

func (l *Lease) Expired() bool

type User

type User struct {
	Email           string
	MainPublicKey   string
	MainPrivateKey  string
	ExpiryDateEpoch int64
	// contains filtered or unexported fields
}

func (*User) Valid

func (u *User) Valid() bool

Jump to

Keyboard shortcuts

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