github.com/prebid/prebid-server/v2@v2.18.0/currency/converter_info.go (about) 1 package currency 2 3 import "time" 4 5 // ConverterInfo holds information about converter setup 6 type ConverterInfo interface { 7 Source() string 8 LastUpdated() time.Time 9 Rates() *map[string]map[string]float64 10 AdditionalInfo() interface{} 11 } 12 13 type converterInfo struct { 14 source string 15 lastUpdated time.Time 16 rates *map[string]map[string]float64 17 additionalInfo interface{} 18 } 19 20 // Source returns converter's URL source 21 func (ci converterInfo) Source() string { 22 return ci.source 23 } 24 25 // LastUpdated returns converter's last updated time 26 func (ci converterInfo) LastUpdated() time.Time { 27 return ci.lastUpdated 28 } 29 30 // Rates returns converter's internal rates 31 func (ci converterInfo) Rates() *map[string]map[string]float64 { 32 return ci.rates 33 } 34 35 // AdditionalInfo returns converter's additional infos 36 func (ci converterInfo) AdditionalInfo() interface{} { 37 return ci.additionalInfo 38 }