source: code/trunk/engine.go@ 6

Last change on this file since 6 was 4, checked in by fattalion, 3 years ago

Use shorter file names

From looking around standard library packages, I see that filenames are
typically single words only (save for the _test prefix and
OS/arch-specific files), so let's follow that style here.

File size: 429 bytes
Line 
1package simplytranslate_engines
2
3type TranslationResult struct {
4 SourceLanguage Language
5 TranslatedText string
6}
7
8type TranslationEngine interface {
9 InternalName() string
10 DisplayName() string
11 SourceLanguages() ([]Language, error)
12 TargetLanguages() ([]Language, error)
13 Translate(text string, from Language, to Language) (TranslationResult, error)
14 SupportsAutodetect() bool
15 DetectLanguage(text string) (Language, error)
16}
Note: See TracBrowser for help on using the repository browser.