Example #1
0
func main() {
	dict, err := embedict.Load()
	if err != nil {
		log.Fatal(err)
	}
	queryLoop(NewConsole(), dict)
}
Example #2
0
func RunDefault() error {
	d, err := embedict.Load()
	if err != nil {
		return err
	}
	migemo := &Migemo{dict: d}

	rpc.Register(migemo)
	rpc.HandleHTTP()
	l, err := net.Listen("tcp", ":1234")
	if err != nil {
		return err
	}
	http.Serve(l, nil)

	return nil
}