8 "github.com/go-playground/locales"
9 "github.com/go-playground/locales/currency"
14 pluralsCardinal []locales.PluralRule
15 pluralsOrdinal []locales.PluralRule
16 pluralsRange []locales.PluralRule
24 currencies []string // idx = enum of currency code
25 currencyNegativePrefix string
26 currencyNegativeSuffix string
27 monthsAbbreviated []string
30 daysAbbreviated []string
34 periodsAbbreviated []string
35 periodsNarrow []string
38 erasAbbreviated []string
41 timezones map[string]string
44 // New returns a new instance of translator for the 'ug_CN' locale
45 func New() locales.Translator {
48 pluralsCardinal: []locales.PluralRule{2, 6},
50 pluralsRange: []locales.PluralRule{2, 6},
58 currencies: []string{"ADP", "AED", "AFA", "AFN", "ALK", "ALL", "AMD", "ANG", "AOA", "AOK", "AON", "AOR", "ARA", "ARL", "ARM", "ARP", "ARS", "ATS", "AUD", "AWG", "AZM", "AZN", "BAD", "BAM", "BAN", "BBD", "BDT", "BEC", "BEF", "BEL", "BGL", "BGM", "BGN", "BGO", "BHD", "BIF", "BMD", "BND", "BOB", "BOL", "BOP", "BOV", "BRB", "BRC", "BRE", "BRL", "BRN", "BRR", "BRZ", "BSD", "BTN", "BUK", "BWP", "BYB", "BYN", "BYR", "BZD", "CAD", "CDF", "CHE", "CHF", "CHW", "CLE", "CLF", "CLP", "CNX", "CNY", "COP", "COU", "CRC", "CSD", "CSK", "CUC", "CUP", "CVE", "CYP", "CZK", "DDM", "DEM", "DJF", "DKK", "DOP", "DZD", "ECS", "ECV", "EEK", "EGP", "ERN", "ESA", "ESB", "ESP", "ETB", "EUR", "FIM", "FJD", "FKP", "FRF", "GBP", "GEK", "GEL", "GHC", "GHS", "GIP", "GMD", "GNF", "GNS", "GQE", "GRD", "GTQ", "GWE", "GWP", "GYD", "HKD", "HNL", "HRD", "HRK", "HTG", "HUF", "IDR", "IEP", "ILP", "ILR", "ILS", "INR", "IQD", "IRR", "ISJ", "ISK", "ITL", "JMD", "JOD", "JPY", "KES", "KGS", "KHR", "KMF", "KPW", "KRH", "KRO", "KRW", "KWD", "KYD", "KZT", "LAK", "LBP", "LKR", "LRD", "LSL", "LTL", "LTT", "LUC", "LUF", "LUL", "LVL", "LVR", "LYD", "MAD", "MAF", "MCF", "MDC", "MDL", "MGA", "MGF", "MKD", "MKN", "MLF", "MMK", "MNT", "MOP", "MRO", "MTL", "MTP", "MUR", "MVP", "MVR", "MWK", "MXN", "MXP", "MXV", "MYR", "MZE", "MZM", "MZN", "NAD", "NGN", "NIC", "NIO", "NLG", "NOK", "NPR", "NZD", "OMR", "PAB", "PEI", "PEN", "PES", "PGK", "PHP", "PKR", "PLN", "PLZ", "PTE", "PYG", "QAR", "RHD", "ROL", "RON", "RSD", "RUB", "RUR", "RWF", "SAR", "SBD", "SCR", "SDD", "SDG", "SDP", "SEK", "SGD", "SHP", "SIT", "SKK", "SLL", "SOS", "SRD", "SRG", "SSP", "STD", "SUR", "SVC", "SYP", "SZL", "THB", "TJR", "TJS", "TMM", "TMT", "TND", "TOP", "TPE", "TRL", "TRY", "TTD", "TWD", "TZS", "UAH", "UAK", "UGS", "UGX", "USD", "USN", "USS", "UYI", "UYP", "UYU", "UZS", "VEB", "VEF", "VND", "VNN", "VUV", "WST", "XAF", "XAG", "XAU", "XBA", "XBB", "XBC", "XBD", "XCD", "XDR", "XEU", "XFO", "XFU", "XOF", "XPD", "XPF", "XPT", "XRE", "XSU", "XTS", "XUA", "XXX", "YDD", "YER", "YUD", "YUM", "YUN", "YUR", "ZAL", "ZAR", "ZMK", "ZMW", "ZRN", "ZRZ", "ZWD", "ZWL", "ZWR"},
59 currencyNegativePrefix: "(",
60 currencyNegativeSuffix: ")",
61 monthsAbbreviated: []string{"", "يانۋار", "فېۋرال", "مارت", "ئاپرېل", "ماي", "ئىيۇن", "ئىيۇل", "ئاۋغۇست", "سېنتەبىر", "ئۆكتەبىر", "نويابىر", "دېكابىر"},
62 monthsNarrow: []string{"", "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12"},
63 monthsWide: []string{"", "يانۋار", "فېۋرال", "مارت", "ئاپرېل", "ماي", "ئىيۇن", "ئىيۇل", "ئاۋغۇست", "سېنتەبىر", "ئۆكتەبىر", "نويابىر", "دېكابىر"},
64 daysAbbreviated: []string{"يە", "دۈ", "سە", "چا", "پە", "جۈ", "شە"},
65 daysNarrow: []string{"ي", "د", "س", "چ", "پ", "ج", "ش"},
66 daysShort: []string{"ي", "د", "س", "چ", "پ", "ج", "ش"},
67 daysWide: []string{"يەكشەنبە", "دۈشەنبە", "سەيشەنبە", "چارشەنبە", "پەيشەنبە", "جۈمە", "شەنبە"},
68 periodsAbbreviated: []string{"چ.ب", "چ.ك"},
69 periodsNarrow: []string{"ب", "ك"},
70 periodsWide: []string{"چۈشتىن بۇرۇن", "چۈشتىن كېيىن"},
71 erasAbbreviated: []string{"BCE", "مىلادىيە"},
72 erasNarrow: []string{"BCE", "مىلادىيە"},
73 erasWide: []string{"مىلادىيەدىن بۇرۇن", "مىلادىيە"},
74 timezones: map[string]string{"COST": "كولومبىيە يازلىق ۋاقتى", "HNT": "نىۋفوئۇنلاند ئۆلچەملىك ۋاقتى", "GMT": "گىرىنۋىچ ۋاقتى", "AEST": "ئاۋسترالىيە شەرقىي قىسىم ئۆلچەملىك ۋاقتى", "HNEG": "شەرقىي گىرېنلاند ئۆلچەملىك ۋاقتى", "SGT": "سىنگاپور ۋاقتى", "CDT": "ئوتتۇرا قىسىم يازلىق ۋاقتى", "AWDT": "ئاۋسترالىيە غەربىي قىسىم يازلىق ۋاقتى", "MEZ": "ئوتتۇرا ياۋروپا ئۆلچەملىك ۋاقتى", "NZDT": "يېڭى زېلاندىيە يازلىق ۋاقتى", "LHDT": "لورد-خاي يازلىق ۋاقتى", "HKST": "شياڭگاڭ يازلىق ۋاقتى", "AKDT": "ئالياسكا يازلىق ۋاقتى", "WESZ": "غەربىي ياۋروپا يازلىق ۋاقتى", "WIB": "غەربىي ھىندونېزىيە ۋاقتى", "HECU": "كۇبا يازلىق ۋاقتى", "AWST": "ئاۋسترالىيە غەربىي قىسىم ئۆلچەملىك ۋاقتى", "LHST": "لورد-خاي ئۆلچەملىك ۋاقتى", "GYT": "گىۋىيانا ۋاقتى", "ChST": "چاموررو ئۆلچەملىك ۋاقتى", "HEPMX": "مېكسىكا تىنچ ئوكيان يازلىق ۋاقتى", "CHADT": "چاتام يازلىق ۋاقتى", "BT": "بۇتان ۋاقتى", "MYT": "مالايشىيا ۋاقتى", "HAT": "نىۋفوئۇنلاند يازلىق ۋاقتى", "WITA": "ئوتتۇرا ھىندونېزىيە ۋاقتى", "AEDT": "ئاۋسترالىيە شەرقىي قىسىم يازلىق ۋاقتى", "MST": "ئاۋمېن ئۆلچەملىك ۋاقتى", "MDT": "ئاۋمېن يازلىق ۋاقتى", "OESZ": "شەرقىي ياۋروپا يازلىق ۋاقتى", "ARST": "ئارگېنتىنا يازلىق ۋاقتى", "GFT": "فىرانسىيەگە قاراشلىق گىۋىيانا ۋاقتى", "HKT": "شياڭگاڭ ئۆلچەملىك ۋاقتى", "PST": "تىنچ ئوكيان ئۆلچەملىك ۋاقتى", "CST": "ئوتتۇرا قىسىم ئۆلچەملىك ۋاقتى", "NZST": "يېڭى زېلاندىيە ئۆلچەملىك ۋاقتى", "HENOMX": "مېكسىكا غەربىي شىمالىي قىسىم يازلىق ۋاقتى", "ACST": "ئاۋسترالىيە ئوتتۇرا قىسىم ئۆلچەملىك ۋاقتى", "HNPM": "ساينىت پىئېر ۋە مىكېلون ئۆلچەملىك ۋاقتى", "WART": "غەربىي ئارگېنتىنا ئۆلچەملىك ۋاقتى", "JST": "ياپونىيە ئۆلچەملىك ۋاقتى", "HEOG": "غەربىي گىرېنلاند يازلىق ۋاقتى", "WAT": "غەربىي ئافرىقا ئۆلچەملىك ۋاقتى", "HEEG": "شەرقىي گىرېنلاند يازلىق ۋاقتى", "EAT": "شەرقىي ئافرىقا ۋاقتى", "PDT": "تىنچ ئوكيان يازلىق ۋاقتى", "WIT": "شەرقىي ھىندونېزىيە ۋاقتى", "OEZ": "شەرقىي ياۋروپا ئۆلچەملىك ۋاقتى", "IST": "ھىندىستان ئۆلچەملىك ۋاقتى", "HNOG": "غەربىي گىرېنلاند ئۆلچەملىك ۋاقتى", "ADT": "ئاتلانتىك ئوكيان يازلىق ۋاقتى", "ECT": "ئېكۋادور ۋاقتى", "CAT": "ئوتتۇرا ئافرىقا ۋاقتى", "ACWDT": "ئاۋسترالىيە ئوتتۇرا غەربىي قىسىم يازلىق ۋاقتى", "TMT": "تۈركمەنىستان ئۆلچەملىك ۋاقتى", "ART": "ئارگېنتىنا ئۆلچەملىك ۋاقتى", "COT": "كولومبىيە ئۆلچەملىك ۋاقتى", "CLT": "چىلى ئۆلچەملىك ۋاقتى", "EST": "شەرقىي قىسىم ئۆلچەملىك ۋاقتى", "BOT": "بولىۋىيە ۋاقتى", "ACWST": "ئاۋستىرالىيە ئوتتۇرا غەربىي قىسىم ئۆلچەملىك ۋاقتى", "WAST": "غەربىي ئافرىقا يازلىق ۋاقتى", "∅∅∅": "ئامازون يازلىق ۋاقتى", "AKST": "ئالياسكا ئۆلچەملىك ۋاقتى", "HNPMX": "مېكسىكا تىنچ ئوكيان ئۆلچەملىك ۋاقتى", "TMST": "تۈركمەنىستان يازلىق ۋاقتى", "JDT": "ياپونىيە يازلىق ۋاقتى", "SAST": "جەنۇبىي ئافرىقا ئۆلچەملىك ۋاقتى", "VET": "ۋېنېزۇئېلا ۋاقتى", "HNNOMX": "مېكسىكا غەربىي شىمالىي قىسىم ئۆلچەملىك ۋاقتى", "CLST": "چىلى يازلىق ۋاقتى", "HEPM": "ساينىت پىئېر ۋە مىكېلون يازلىق ۋاقتى", "HNCU": "كۇبا ئۆلچەملىك ۋاقتى", "UYST": "ئۇرۇگۋاي يازلىق ۋاقتى", "MESZ": "ئوتتۇرا ياۋروپا يازلىق ۋاقتى", "HAST": "ھاۋاي-ئالېيۇت ئۆلچەملىك ۋاقتى", "WARST": "غەربىي ئارگېنتىنا يازلىق ۋاقتى", "ACDT": "ئاۋسترالىيە ئوتتۇرا قىسىم يازلىق ۋاقتى", "WEZ": "غەربىي ياۋروپا ئۆلچەملىك ۋاقتى", "CHAST": "چاتام ئۆلچەملىك ۋاقتى", "SRT": "سۇرىنام ۋاقتى", "UYT": "ئۇرۇگۋاي ئۆلچەملىك ۋاقتى", "HADT": "ھاۋاي-ئالېيۇت يازلىق ۋاقتى", "EDT": "شەرقىي قىسىم يازلىق ۋاقتى", "AST": "ئاتلانتىك ئوكيان ئۆلچەملىك ۋاقتى"},
78 // Locale returns the current translators string locale
79 func (ug *ug_CN) Locale() string {
83 // PluralsCardinal returns the list of cardinal plural rules associated with 'ug_CN'
84 func (ug *ug_CN) PluralsCardinal() []locales.PluralRule {
85 return ug.pluralsCardinal
88 // PluralsOrdinal returns the list of ordinal plural rules associated with 'ug_CN'
89 func (ug *ug_CN) PluralsOrdinal() []locales.PluralRule {
90 return ug.pluralsOrdinal
93 // PluralsRange returns the list of range plural rules associated with 'ug_CN'
94 func (ug *ug_CN) PluralsRange() []locales.PluralRule {
95 return ug.pluralsRange
98 // CardinalPluralRule returns the cardinal PluralRule given 'num' and digits/precision of 'v' for 'ug_CN'
99 func (ug *ug_CN) CardinalPluralRule(num float64, v uint64) locales.PluralRule {
104 return locales.PluralRuleOne
107 return locales.PluralRuleOther
110 // OrdinalPluralRule returns the ordinal PluralRule given 'num' and digits/precision of 'v' for 'ug_CN'
111 func (ug *ug_CN) OrdinalPluralRule(num float64, v uint64) locales.PluralRule {
112 return locales.PluralRuleUnknown
115 // RangePluralRule returns the ordinal PluralRule given 'num1', 'num2' and digits/precision of 'v1' and 'v2' for 'ug_CN'
116 func (ug *ug_CN) RangePluralRule(num1 float64, v1 uint64, num2 float64, v2 uint64) locales.PluralRule {
118 start := ug.CardinalPluralRule(num1, v1)
119 end := ug.CardinalPluralRule(num2, v2)
121 if start == locales.PluralRuleOne && end == locales.PluralRuleOther {
122 return locales.PluralRuleOther
123 } else if start == locales.PluralRuleOther && end == locales.PluralRuleOne {
124 return locales.PluralRuleOne
127 return locales.PluralRuleOther
131 // MonthAbbreviated returns the locales abbreviated month given the 'month' provided
132 func (ug *ug_CN) MonthAbbreviated(month time.Month) string {
133 return ug.monthsAbbreviated[month]
136 // MonthsAbbreviated returns the locales abbreviated months
137 func (ug *ug_CN) MonthsAbbreviated() []string {
138 return ug.monthsAbbreviated[1:]
141 // MonthNarrow returns the locales narrow month given the 'month' provided
142 func (ug *ug_CN) MonthNarrow(month time.Month) string {
143 return ug.monthsNarrow[month]
146 // MonthsNarrow returns the locales narrow months
147 func (ug *ug_CN) MonthsNarrow() []string {
148 return ug.monthsNarrow[1:]
151 // MonthWide returns the locales wide month given the 'month' provided
152 func (ug *ug_CN) MonthWide(month time.Month) string {
153 return ug.monthsWide[month]
156 // MonthsWide returns the locales wide months
157 func (ug *ug_CN) MonthsWide() []string {
158 return ug.monthsWide[1:]
161 // WeekdayAbbreviated returns the locales abbreviated weekday given the 'weekday' provided
162 func (ug *ug_CN) WeekdayAbbreviated(weekday time.Weekday) string {
163 return ug.daysAbbreviated[weekday]
166 // WeekdaysAbbreviated returns the locales abbreviated weekdays
167 func (ug *ug_CN) WeekdaysAbbreviated() []string {
168 return ug.daysAbbreviated
171 // WeekdayNarrow returns the locales narrow weekday given the 'weekday' provided
172 func (ug *ug_CN) WeekdayNarrow(weekday time.Weekday) string {
173 return ug.daysNarrow[weekday]
176 // WeekdaysNarrow returns the locales narrow weekdays
177 func (ug *ug_CN) WeekdaysNarrow() []string {
181 // WeekdayShort returns the locales short weekday given the 'weekday' provided
182 func (ug *ug_CN) WeekdayShort(weekday time.Weekday) string {
183 return ug.daysShort[weekday]
186 // WeekdaysShort returns the locales short weekdays
187 func (ug *ug_CN) WeekdaysShort() []string {
191 // WeekdayWide returns the locales wide weekday given the 'weekday' provided
192 func (ug *ug_CN) WeekdayWide(weekday time.Weekday) string {
193 return ug.daysWide[weekday]
196 // WeekdaysWide returns the locales wide weekdays
197 func (ug *ug_CN) WeekdaysWide() []string {
201 // Decimal returns the decimal point of number
202 func (ug *ug_CN) Decimal() string {
206 // Group returns the group of number
207 func (ug *ug_CN) Group() string {
211 // Group returns the minus sign of number
212 func (ug *ug_CN) Minus() string {
216 // FmtNumber returns 'num' with digits/precision of 'v' for 'ug_CN' and handles both Whole and Real numbers based on 'v'
217 func (ug *ug_CN) FmtNumber(num float64, v uint64) string {
219 s := strconv.FormatFloat(math.Abs(num), 'f', int(v), 64)
220 l := len(s) + 2 + 1*len(s[:len(s)-int(v)-1])/3
223 b := make([]byte, 0, l)
225 for i := len(s) - 1; i >= 0; i-- {
228 b = append(b, ug.decimal[0])
235 b = append(b, ug.group[0])
246 b = append(b, ug.minus[0])
250 for i, j := 0, len(b)-1; i < j; i, j = i+1, j-1 {
251 b[i], b[j] = b[j], b[i]
257 // FmtPercent returns 'num' with digits/precision of 'v' for 'ug_CN' and handles both Whole and Real numbers based on 'v'
258 // NOTE: 'num' passed into FmtPercent is assumed to be in percent already
259 func (ug *ug_CN) FmtPercent(num float64, v uint64) string {
260 s := strconv.FormatFloat(math.Abs(num), 'f', int(v), 64)
262 b := make([]byte, 0, l)
264 for i := len(s) - 1; i >= 0; i-- {
267 b = append(b, ug.decimal[0])
275 b = append(b, ug.minus[0])
279 for i, j := 0, len(b)-1; i < j; i, j = i+1, j-1 {
280 b[i], b[j] = b[j], b[i]
283 b = append(b, ug.percent...)
288 // FmtCurrency returns the currency representation of 'num' with digits/precision of 'v' for 'ug_CN'
289 func (ug *ug_CN) FmtCurrency(num float64, v uint64, currency currency.Type) string {
291 s := strconv.FormatFloat(math.Abs(num), 'f', int(v), 64)
292 symbol := ug.currencies[currency]
293 l := len(s) + len(symbol) + 2 + 1*len(s[:len(s)-int(v)-1])/3
296 b := make([]byte, 0, l)
298 for i := len(s) - 1; i >= 0; i-- {
301 b = append(b, ug.decimal[0])
308 b = append(b, ug.group[0])
318 for j := len(symbol) - 1; j >= 0; j-- {
319 b = append(b, symbol[j])
323 b = append(b, ug.minus[0])
327 for i, j := 0, len(b)-1; i < j; i, j = i+1, j-1 {
328 b[i], b[j] = b[j], b[i]
334 b = append(b, ug.decimal...)
337 for i := 0; i < 2-int(v); i++ {
345 // FmtAccounting returns the currency representation of 'num' with digits/precision of 'v' for 'ug_CN'
346 // in accounting notation.
347 func (ug *ug_CN) FmtAccounting(num float64, v uint64, currency currency.Type) string {
349 s := strconv.FormatFloat(math.Abs(num), 'f', int(v), 64)
350 symbol := ug.currencies[currency]
351 l := len(s) + len(symbol) + 4 + 1*len(s[:len(s)-int(v)-1])/3
354 b := make([]byte, 0, l)
356 for i := len(s) - 1; i >= 0; i-- {
359 b = append(b, ug.decimal[0])
366 b = append(b, ug.group[0])
378 for j := len(symbol) - 1; j >= 0; j-- {
379 b = append(b, symbol[j])
382 b = append(b, ug.currencyNegativePrefix[0])
386 for j := len(symbol) - 1; j >= 0; j-- {
387 b = append(b, symbol[j])
393 for i, j := 0, len(b)-1; i < j; i, j = i+1, j-1 {
394 b[i], b[j] = b[j], b[i]
400 b = append(b, ug.decimal...)
403 for i := 0; i < 2-int(v); i++ {
409 b = append(b, ug.currencyNegativeSuffix...)
415 // FmtDateShort returns the short date representation of 't' for 'ug_CN'
416 func (ug *ug_CN) FmtDateShort(t time.Time) string {
418 b := make([]byte, 0, 32)
421 b = strconv.AppendInt(b, int64(t.Year()), 10)
423 b = strconv.AppendInt(b, int64(-t.Year()), 10)
426 b = append(b, []byte{0x2d}...)
432 b = strconv.AppendInt(b, int64(t.Month()), 10)
434 b = append(b, []byte{0x2d}...)
440 b = strconv.AppendInt(b, int64(t.Day()), 10)
445 // FmtDateMedium returns the medium date representation of 't' for 'ug_CN'
446 func (ug *ug_CN) FmtDateMedium(t time.Time) string {
448 b := make([]byte, 0, 32)
450 b = strconv.AppendInt(b, int64(t.Day()), 10)
451 b = append(b, []byte{0x2d}...)
452 b = append(b, ug.monthsAbbreviated[t.Month()]...)
453 b = append(b, []byte{0xd8, 0x8c, 0x20}...)
456 b = strconv.AppendInt(b, int64(t.Year()), 10)
458 b = strconv.AppendInt(b, int64(-t.Year()), 10)
464 // FmtDateLong returns the long date representation of 't' for 'ug_CN'
465 func (ug *ug_CN) FmtDateLong(t time.Time) string {
467 b := make([]byte, 0, 32)
469 b = strconv.AppendInt(b, int64(t.Day()), 10)
470 b = append(b, []byte{0x2d}...)
471 b = append(b, ug.monthsWide[t.Month()]...)
472 b = append(b, []byte{0xd8, 0x8c, 0x20}...)
475 b = strconv.AppendInt(b, int64(t.Year()), 10)
477 b = strconv.AppendInt(b, int64(-t.Year()), 10)
483 // FmtDateFull returns the full date representation of 't' for 'ug_CN'
484 func (ug *ug_CN) FmtDateFull(t time.Time) string {
486 b := make([]byte, 0, 32)
489 b = strconv.AppendInt(b, int64(t.Year()), 10)
491 b = strconv.AppendInt(b, int64(-t.Year()), 10)
494 b = append(b, []byte{0x20}...)
495 b = strconv.AppendInt(b, int64(t.Day()), 10)
496 b = append(b, []byte{0x2d}...)
497 b = append(b, ug.monthsWide[t.Month()]...)
498 b = append(b, []byte{0xd8, 0x8c, 0x20}...)
499 b = append(b, ug.daysWide[t.Weekday()]...)
504 // FmtTimeShort returns the short time representation of 't' for 'ug_CN'
505 func (ug *ug_CN) FmtTimeShort(t time.Time) string {
507 b := make([]byte, 0, 32)
515 b = strconv.AppendInt(b, int64(h), 10)
516 b = append(b, ug.timeSeparator...)
522 b = strconv.AppendInt(b, int64(t.Minute()), 10)
523 b = append(b, []byte{0x20}...)
526 b = append(b, ug.periodsAbbreviated[0]...)
528 b = append(b, ug.periodsAbbreviated[1]...)
534 // FmtTimeMedium returns the medium time representation of 't' for 'ug_CN'
535 func (ug *ug_CN) FmtTimeMedium(t time.Time) string {
537 b := make([]byte, 0, 32)
545 b = strconv.AppendInt(b, int64(h), 10)
546 b = append(b, ug.timeSeparator...)
552 b = strconv.AppendInt(b, int64(t.Minute()), 10)
553 b = append(b, ug.timeSeparator...)
559 b = strconv.AppendInt(b, int64(t.Second()), 10)
560 b = append(b, []byte{0x20}...)
563 b = append(b, ug.periodsAbbreviated[0]...)
565 b = append(b, ug.periodsAbbreviated[1]...)
571 // FmtTimeLong returns the long time representation of 't' for 'ug_CN'
572 func (ug *ug_CN) FmtTimeLong(t time.Time) string {
574 b := make([]byte, 0, 32)
582 b = strconv.AppendInt(b, int64(h), 10)
583 b = append(b, ug.timeSeparator...)
589 b = strconv.AppendInt(b, int64(t.Minute()), 10)
590 b = append(b, ug.timeSeparator...)
596 b = strconv.AppendInt(b, int64(t.Second()), 10)
597 b = append(b, []byte{0x20}...)
600 b = append(b, ug.periodsAbbreviated[0]...)
602 b = append(b, ug.periodsAbbreviated[1]...)
605 b = append(b, []byte{0x20}...)
613 // FmtTimeFull returns the full time representation of 't' for 'ug_CN'
614 func (ug *ug_CN) FmtTimeFull(t time.Time) string {
616 b := make([]byte, 0, 32)
624 b = strconv.AppendInt(b, int64(h), 10)
625 b = append(b, ug.timeSeparator...)
631 b = strconv.AppendInt(b, int64(t.Minute()), 10)
632 b = append(b, ug.timeSeparator...)
638 b = strconv.AppendInt(b, int64(t.Second()), 10)
639 b = append(b, []byte{0x20}...)
642 b = append(b, ug.periodsAbbreviated[0]...)
644 b = append(b, ug.periodsAbbreviated[1]...)
647 b = append(b, []byte{0x20}...)
651 if btz, ok := ug.timezones[tz]; ok {
652 b = append(b, btz...)