dict

package
v0.0.0-...-52f8398 Latest Latest
Warning

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

Go to latest
Published: Apr 17, 2016 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Engine

type Engine struct {
}

Engine dict engine

func (*Engine) Map

func (p *Engine) Map(inj inject.Injector) martini.Handler

Map map objects

func (*Engine) Migrate

func (p *Engine) Migrate() martini.Handler

Migrate call by db:migrate

func (*Engine) Mount

func (p *Engine) Mount(rt martini.Router)

Mount mount to web

func (*Engine) Seed

func (p *Engine) Seed() martini.Handler

Seed call by db:seed

func (*Engine) Shell

func (p *Engine) Shell() []cli.Command

Shell shell commands

func (*Engine) Worker

func (p *Engine) Worker() martini.Handler

Worker call by worker

type Note

type Note struct {
	web.Model
	Title  string `gorm:"not null;index;type:VARCHAR(255)" json:"title"`
	Body   string `gorm:"not null;type:TEXT" json:"body"`
	UserID uint   `gorm:"not null" json:"userId"`
	User   oauth.User
}

Note word note

func (Note) TableName

func (Note) TableName() string

TableName table name

type Provider

type Provider interface {
	List() (map[string]int, error)
	Query(string) (string, error)
}

Provider dict model

type StarDict

type StarDict struct {
	Dir string
}

StarDict sdcv provider

func (*StarDict) List

func (p *StarDict) List() (map[string]int, error)

List list all dictionaries

func (*StarDict) Query

func (p *StarDict) Query(key string) (string, error)

Query search in dictionaries

Jump to

Keyboard shortcuts

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