language

package
v0.0.0-...-894ab8b Latest Latest
Warning

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

Go to latest
Published: Aug 31, 2014 License: MIT Imports: 1 Imported by: 9

Documentation

Overview

Package language defines language codes, the language struct, and the language server interface.

Index

Constants

This section is empty.

Variables

View Source
var CodeNotFound = errors.New("Language code not found")
View Source
var English = Language{
	Code:      "en",
	ISO_639_1: "en",
	ISO_639_3: "eng",
	WikiData:  "",
}
View Source
var None = Language{Code: "none"}
View Source
var Unknown = Language{Code: "unknown"}

Functions

This section is empty.

Types

type Code

type Code string

type CodeSlice

type CodeSlice []Code

func (CodeSlice) Len

func (s CodeSlice) Len() int

func (CodeSlice) Less

func (s CodeSlice) Less(i, j int) bool

func (CodeSlice) Swap

func (s CodeSlice) Swap(i, j int)

type Language

type Language struct {
	Code      Code
	ISO_639_1 string
	ISO_639_3 string
	WikiData  string
}

type Server

type Server interface {
	List() ([]Code, error)
	GetCode(maybeCode string) (Code, error)
}

Server is the interface a language server should comply to.

Directories

Path Synopsis
Package rpc provides the rpc language client used by the Polyglottis Application and a simple language server wrapper.
Package rpc provides the rpc language client used by the Polyglottis Application and a simple language server wrapper.

Jump to

Keyboard shortcuts

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