• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // Copyright 2014 The PDFium Authors
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4 
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6 
7 #ifndef XFA_FGAS_CRT_LOCALE_IFACE_H_
8 #define XFA_FGAS_CRT_LOCALE_IFACE_H_
9 
10 #include "core/fxcrt/widestring.h"
11 
12 class LocaleIface {
13  public:
14   enum class DateTimeSubcategory {
15     kDefault,
16     kShort,
17     kMedium,
18     kFull,
19     kLong,
20   };
21 
22   enum class NumSubcategory {
23     kPercent,
24     kCurrency,
25     kDecimal,
26     kInteger,
27   };
28 
29   virtual ~LocaleIface() = default;
30 
31   virtual WideString GetName() const = 0;
32   virtual WideString GetDecimalSymbol() const = 0;
33   virtual WideString GetGroupingSymbol() const = 0;
34   virtual WideString GetPercentSymbol() const = 0;
35   virtual WideString GetMinusSymbol() const = 0;
36   virtual WideString GetCurrencySymbol() const = 0;
37   virtual WideString GetDateTimeSymbols() const = 0;
38   virtual WideString GetMonthName(int32_t nMonth, bool bAbbr) const = 0;
39   virtual WideString GetDayName(int32_t nWeek, bool bAbbr) const = 0;
40   virtual WideString GetMeridiemName(bool bAM) const = 0;
41   virtual int GetTimeZoneInMinutes() const = 0;
42   virtual WideString GetEraName(bool bAD) const = 0;
43   virtual WideString GetDatePattern(DateTimeSubcategory eType) const = 0;
44   virtual WideString GetTimePattern(DateTimeSubcategory eType) const = 0;
45   virtual WideString GetNumPattern(NumSubcategory eType) const = 0;
46 };
47 
48 #endif  // XFA_FGAS_CRT_LOCALE_IFACE_H_
49