Wide Studio Object Reference

Wide Studio Home
Up to


Class Name

WSClocaleSet

Specification of methods



WSGIappLocaleSet Function Description

Form
WSClocaleSet* WSGIappLocaleSet()
Function
Obtain a global instance of encoding information management class existing for each application
Description
Parameters
None.
Return value
A pointer to encode information management class instance
Notice
This is a global function, not a member function. Do not release the returned pointer.
Samples
  //Obtain an encode information management class instance existing for each process
  WSClocaleSet* localeset = WSGIappLocaleSet();



getDefaultLocaleName Function Description

Form
char* getDefaultLocaleName()
Function
Obtain a default locale name
Description
Parameters
None.
Return value
Locale name
Notice
Do not release the returned locale name
Samples
  //Do the following to obtain a locale name
  char* lname = WSGIappLocaleSet()->getDefaultLocaleName();



setDefaultEncoding Function Description

Form
void setDefaultEncoding(long encoding)
Function
Set default encoding
Description
Parameters
(in)long encoding Encoding

The following are supported as encoding
Encoding Meaning
WS_EN_DEFAULT Specify current setting (default value)
WS_EN_LOCALE Specify current LANG environment setting
WS_EN_NONE Specify nothing.
WS_EN_ISO8859_1 Specify ISO8859(1)
WS_EN_ISO8859_2 Specify ISO8859(2)
WS_EN_ISO8859_3 Specify ISO8859(3)
WS_EN_ISO8859_4 Specify ISO8859(4)
WS_EN_ISO8859_5 Specify ISO8859(5)
WS_EN_ISO8859_6 Specify ISO8859(6)
WS_EN_ISO8859_7 Specify ISO8859(7)
WS_EN_ISO8859_8 Specify ISO8859(8)
WS_EN_ISO8859_9 Specify ISO8859(9)
WS_EN_ISO8859_10 Specify ISO8859(10)
WS_EN_ISO8859_11 Specify ISO8859(11)
WS_EN_ISO8859_12 Specify ISO8859(12)
WS_EN_ISO8859_13 Specify ISO8859(13)
WS_EN_ISO8859_14 Specify ISO8859(14)
WS_EN_ISO8859_15 Specify ISO8859(15)
WS_EN_UTF8 Specify UTF8
WS_EN_KOI8R Specify KOI8R
WS_EN_EUCJP Specify EUCJP
WS_EN_SJIS Specify SJIS
WS_EN_EUCKR Specify EUCKR
WS_EN_EUCCN Specify EUCCN
WS_EN_BIG5 Specify BIG5
Return value
None.
Notice
Samples
  //Do the following to set EUCJP as default encoding
  WSGIappLocaleSet()->setDefaultEncoding(WS_EN_EUCJP);



getDefaultEncoding Function Description

Form
long getDefaultEncoding()
Function
Obtain default encoding
Description
Parameters
None.
Return value
Encoding
Refer to arguments of setDefaultEncoding function
Notice
Samples
  //Do the following to obtain default encoding
  long encoding = WSGIappLocaleSet()->getDefaultEncoding();



getSystemLocaleEncoding Function Description

Form
long getSystemLocaleEncoding()
Function
Obtain encoding used in the system I/O
Description
Parameters
None.
Return value
Encoding
Refer to arguments of setDefaultEncoding function
Notice
Samples
  //Do the following to obtain encoding of system I/O
  long encoding = WSGIappLocaleSet()->getSystemLocaleEncoding();



getLocaleString Function Description

Form
char* getLocaleString(char* locale,char* index,long encode)
Function
Obtain strings of each specified locale language.
Description
Obtain strings corresponding to the specified index strings out of registered strings by each language against index strings by languages beforehand
Parameters
(in)char* locale Locale name
(in)char* index Index strings
(in)long encoding String encoding to obtain

Refer to arguments of setDefaultEncoding function
Return value
Strings by language
Notice
Samples
  //Do the following to obtain a locale transform strings registered beforehand.
  char* str = WSGIappLocaleSet()->getLocaleString("EUCJP","test string",WS_EN_EUCJP);


Document Release 3.20

For use with Wide Studio Release 3.20, Spring 2003


Wide Studio Home | Up to

Copyright(C) T. Hirabayashi, 1999-2003 Last modified: February 3, 2003