Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DeeplRequestResponse ¶
type DeeplRequestResponse struct {
Translations []DeeplRequestResponseTranslation
}
type DeeplRequestUsage ¶
type T2Service ¶
type T2Service struct {
// contains filtered or unexported fields
}
func NewT2 ¶
func NewT2(config T2Config, tr Translation) T2Service
func (T2Service) TraductionTranslation ¶
type Translation ¶
type Translation interface {
Translate(text string, source string, target string) (TranslationResponse, error)
Usage() (UsageResponse, error)
}
type TranslationDeepl ¶
func (TranslationDeepl) Translate ¶
func (d TranslationDeepl) Translate(text string, source string, target string) (TranslationResponse, error)
func (TranslationDeepl) Usage ¶
func (d TranslationDeepl) Usage() (UsageResponse, error)
type TranslationResponse ¶
type TranslationResponse struct {
Text string
}
type UsageResponse ¶
Click to show internal directories.
Click to hide internal directories.