1/* 2 * Copyright (c) 2021 Huawei Device Co., Ltd. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16#ifndef ECMASCRIPT_BUILTINS_BUILTINS_LOCALE_H 17#define ECMASCRIPT_BUILTINS_BUILTINS_LOCALE_H 18 19#include "ecmascript/base/builtins_base.h" 20 21namespace panda::ecmascript::builtins { 22class BuiltinsLocale : public base::BuiltinsBase { 23public: 24 // 10.1.3 Intl.Locale( tag [, options] ) 25 static JSTaggedValue LocaleConstructor(EcmaRuntimeCallInfo *argv); 26 27 // 10.3.3 Intl.Locale.prototype.maximize () 28 static JSTaggedValue Maximize(EcmaRuntimeCallInfo *argv); 29 // 10.3.4 Intl.Locale.prototype.minimize () 30 static JSTaggedValue Minimize(EcmaRuntimeCallInfo *argv); 31 // 10.3.5 Intl.Locale.prototype.toString () 32 static JSTaggedValue ToString(EcmaRuntimeCallInfo *argv); 33 34 // 10.3.6 get Intl.Locale.prototype.baseName 35 static JSTaggedValue GetBaseName(EcmaRuntimeCallInfo *argv); 36 // 10.3.7 get Intl.Locale.prototype.calendar 37 static JSTaggedValue GetCalendar(EcmaRuntimeCallInfo *argv); 38 // 10.3.8 get Intl.Locale.prototype.caseFirst 39 static JSTaggedValue GetCaseFirst(EcmaRuntimeCallInfo *argv); 40 // 10.3.9 get Intl.Locale.prototype.collation 41 static JSTaggedValue GetCollation(EcmaRuntimeCallInfo *argv); 42 // 10.3.10 get Intl.Locale.prototype.hourCycle 43 static JSTaggedValue GetHourCycle(EcmaRuntimeCallInfo *argv); 44 // 10.3.11 get Intl.Locale.prototype.numeric 45 static JSTaggedValue GetNumeric(EcmaRuntimeCallInfo *argv); 46 // 10.3.12 get Intl.Locale.prototype.numberingSystem 47 static JSTaggedValue GetNumberingSystem(EcmaRuntimeCallInfo *argv); 48 // 10.3.13 get Intl.Locale.prototype.language 49 static JSTaggedValue GetLanguage(EcmaRuntimeCallInfo *argv); 50 // 10.3.14 get Intl.Locale.prototype.script 51 static JSTaggedValue GetScript(EcmaRuntimeCallInfo *argv); 52 // 10.3.15 get Intl.Locale.prototype.region 53 static JSTaggedValue GetRegion(EcmaRuntimeCallInfo *argv); 54}; 55} // namespace panda::ecmascript::builtins 56#endif // ECMASCRIPT_BUILTINS_BUILTINS_LOCALE_H