diff --git a/trans/trans.go b/trans/trans.go index 1340d5d..39ed8c7 100644 --- a/trans/trans.go +++ b/trans/trans.go @@ -7,6 +7,9 @@ import ( "log" ) +type Translator interface { + Translate() []string +} type transJob struct { word string @@ -14,7 +17,7 @@ type transJob struct { toLang string } -func New(word, fromLang, toLang string) transJob { +func New(word, fromLang, toLang string) Translator { return transJob{word: word, fromLang: fromLang, toLang: toLang} }