How to Set Language Programmatically Using API: Difference between revisions

From wizarPOS
(Created page with "The system provides the AIDL interface to set language, When connect the service, the package name is '''com.wizarpos.wizarviewagentassistant''', and the class name is '''com....")
 
No edit summary
Line 1: Line 1:
The system provides the AIDL interface to set language, When connect the service, the package name is '''com.wizarpos.wizarviewagentassistant''', and the class name is '''com.wizarpos.wizarviewagentassistant.SystemExtApiService'''. When the application uses the interface, it must import wizarviewagentassistant.
== Interface and Class Details ==
 
* Package Name: ''''com.wizarpos.wizarviewagentassistant''''
Version of wizarviewagentassistant should equal or larger than 2.10.60.
* Class Name: ''''com.wizarpos.wizarviewagentassistant.SystemExtApiService''''
== API Overview ==
* Ensure to import ''''wizarviewagentassistant'''' when using this interface.
=== <big>setLanguage</big>===
== Version Requirement ==
  <syntaxhighlight lang="java">boolean setLanguage(String language, String country, String variant);</syntaxhighlight>
* The version of ''''wizarviewagentassistant'''' should be 2.10.60 or higher.
Set language.  
== API Function ==
 
=== <big>Set Language</big> ===
* ''''boolean setLanguage(String language, String country, String variant)'''';
* Sets the system language. Specify the language, country, and any variant if applicable.
{|class="wizarpostable"
{|class="wizarpostable"
|-
|-
Line 27: Line 29:
|  boolean || true:set success ; false: set failed;
|  boolean || true:set success ; false: set failed;
|}
|}
 
== Resources for Download ==
== Download ==
* '''AIDL File:''' Download the necessary [http://ftp.wizarpos.com/advanceSDK/ISystemExtApi.aidl AIDL file] for implementation.
=== AIDL===
* '''Demo:''' A [http://ftp.wizarpos.com/advanceSDK/example_enableethernet_mtp_setlanguage.7z demo] is available for download to provide practical guidance.
Please download the [http://ftp.wizarpos.com/advanceSDK/ISystemExtApi.aidl AIDL]
=== Demo ===
Please download the [http://ftp.wizarpos.com/advanceSDK/example_enableethernet_mtp_setlanguage.7z demo]

Revision as of 21:31, 2 January 2024

Interface and Class Details

  • Package Name: 'com.wizarpos.wizarviewagentassistant'
  • Class Name: 'com.wizarpos.wizarviewagentassistant.SystemExtApiService'
  • Ensure to import 'wizarviewagentassistant' when using this interface.

Version Requirement

  • The version of 'wizarviewagentassistant' should be 2.10.60 or higher.

API Function

Set Language

  • 'boolean setLanguage(String language, String country, String variant)';
  • Sets the system language. Specify the language, country, and any variant if applicable.
Parameters
language String : (Null is not allowed)An ISO 639 alpha-2 or alpha-3 language code, or a language subtag up to 8 characters in length. See the Locale class description about valid language values.
country String : (Null is allowed)An ISO 3166 alpha-2 country code or a UN M.49 numeric-3 area code. See the Locale class description about valid country values.
variant String : (Null is allowed)Any arbitrary value used to indicate a variation of a Locale. See the Locale class description for the details.
Returns
boolean true:set success ; false: set failed;

Resources for Download

  • AIDL File: Download the necessary AIDL file for implementation.
  • Demo: A demo is available for download to provide practical guidance.