globalization development kit building global internet application simon law product manager oracle...

26

Upload: kory-blair

Post on 28-Dec-2015

213 views

Category:

Documents


0 download

TRANSCRIPT

Globalization Development KitBuilding Global Internet

Application

Simon LawProduct Manager

Oracle Corporation

Session id: 40127

Globalization Development Kit

What is the GDK ?– A toolkit that simplifies the development process,

and reduces the cost of developing Internet applications that will be used to support a global environment

The need for the GDK– The complexity associated with the different

globalization concepts, can make building and supporting a global Internet application quite a challenge for many companies.

Internet and Oracle Services

Oracle’s Globalization Platform for J2EE Internet Services

– provides the development support for the J2EE middle tier to hide the complexity of synchronizing globalization operations across tiers

Oracle Services – provides development support in the middle tier

to provide consistent globalization operations as provided in the database server

Monolingual Model

English Locale

Japanese Locale

Application Server A

Thai Locale

ISO-8859-1

Shift- JIS

TIS- 620

Application Server B

MonolingualEnglish

ApplicationServer Instance1

ApplicationServer Instance2

MonolingualJapanese

Oracle Unicode DatabaseApplication

Server Instance

MonolingualJapanese

Multilingual Model

Oracle Unicode Database

English Locale

Japanese Locale

Thai Locale

ISO-8859-1

Shift- JIS

TIS- 620

Application Server

ApplicationServer Instance

MultilingualEnglish,

Japanese, Thai

Developing a Global Internet Application

Determining the user locale preference and synchronizing it with the application

Specifying the character set for the input and output of web content

Staging and managing translated content Getting consistent globalization operations

between the application and the database

Locale Type Source

HTTP language preferenceBrowser

User Input Locale Menu

Locale preference from databaseDatabase

LDAP locale preference LDAP

Application default locale GDK

Locale Type Source

HTTP language preferenceBrowser

User Input Locale Menu

Locale preference from databaseDatabase

LDAP locale preference LDAP

Application default locale GDK

Supported Locale Sources

GDK Application configuration file

Dictates the globalization behaviors and the properties of the application

One application configuration file per J2EE application

Alter the globalization behavior in the application, without the need to change the programs and to recompile them

Defining the locale sources and the application locales

Application configuration file: gdkapp.xml

<locale-source> oracle.i18n.servlet.localeldap.LDAPInetOrgPerson</locale-source>

<locale-source> oracle.i18n.servlet.localesource.HTTPAcceptLanguage

</locale-source>

<application-locales> <locale>de-*</locale> <locale>ja</locale> <locale default="yes">en-US</locale></application-locales>

Detecting the Locale

Locale loc = request.getLocale( );

Localizer localizer = ServletHelper.getLocalizerInstance(request);

The GDK Localizer is an all-in-one globalization object that encapsulates comprehensive globalization attributes and methods

Character set for the input and output of web content

A single local character set dedicated to the whole application

Use Unicode UTF-8 for all contents regardless of the language

Use the native character set for each language

AUTO-CHARSETISO ISO localelocale

NLS_LANGUAGENLS_LANGUAGE NLS_TERRITORY IANA Character Set

ar-SA ARABIC SAUDI ARABIA WINDOWS-1256

de-DE GERMAN GERMANY WINDOWS-1252

en-US AMERICAN AMERICA WINDOWS-1252

en-GB ENGLISH UNITED KINGDOM WINDOWS-1252

el GREEK GREECE WINDOWS-1253

es-ES SPANISH SPAIN WINDOWS-1252

fr FRENCH FRANCE WINDOWS-1252

fr-CA CANADIAN FRENCH CANADA WINDOWS-1252

iw HEBREW ISRAEL WINDOWS-1255

ko KOREAN KOREA EUC-KR

ja JAPANESE JAPAN SHIFT_JIS

it ITALIAN ITALY WINDOWS-1252

pt PORTUGUESE PORTUGAL WINDOWS-1252

pt-BR BRAZILIAN PORTUGUESE BRAZIL WINDOWS-1252

tr TURKISH TURKEY WINDOWS-1254

nl DUTCH THE NETHERLANDS

WINDOWS-1252

zh SIMPLIFIED CHINESE CHINA GBK

zh-TW TRADITIONAL CHINESE

TAIWAN BIG5

Handling the character set

Specify the Character set in the application configuration file.

<page-charset>UTF-8</page-charset>

<page-charset>AUTO-CHARSET</page-charset>

<locale-charset-maps> <locale-charset> <locale>ja</locale><charset>EUC-JP</charset> </locale-charset></locale-charset-maps>

Managing translated content

Static Files – HTML, GIF, XML etc. French version of index.html > index_fr.html or fr/index.html

ServletHelper.rewriteURL ( ) method rewrites a URL based on the rules specified in the application configuration file.

<img src="<%=“

ServletHelper.rewriteURL("logo.jpg",request)%>">

Managing translated content

Strings in the JSP / JAVA Servlets Externalized into Java ResourceBundle

REPLACE

<% Locale user_locale=request.getLocale(); ResourceBundlerb=ResourceBundle.getBundle("resource",user_locale); %>

<%= rb.getString("Welcome") %>

WITH

% Localizer.getMessage ("Welcome") %>

Globalization compatibility between Java & Oracle

No Globalization Standard Lengthy lead time for Java to add new locale

support The GDK extends Oracle Globalization

Support features to the application server Handles the compatibility between the Java

and the Oracle database server seamlessly

Not available in Java 1.4.2

Languages

BANGLADESHCYPRUSDJIBOUTIINDONESIAKAZAKHSTANMALAYSIAMAURITANIASINGAPORESOMALIAUZBEKISTANVIETNAM

ASSAMESEBANGLABENGALIGERMAN DINGUJARATIINDONESIANKANNADALATIN AMERICAN SPANISHMALAYMALAYALAMMARATHIORIYAPUNJABITAMILTELUGUVIETNAMESE

AR8ADOS710AR8ADOS710TAR8ADOS720AR8ADOS720TAR8APTEC715APTEC715TAR8ASMO708PLUSAR8ASMO8XAR8HPARABIC8TAR8MUSSAD768AR8MUSSAD768TAR8NAFITHA711AR8NAFITHA711TAR8NAFITHA721AR8NAFITHA721TAR8SAKHR706AR8SAKHR707AR8SAKHR707TAR8XBASICBG8MSWINBG8PC437SBN8BSCIICE8BS2000CEL8ISO8859P14CH7DECCL8BS2000CL8EBCDIC1158CL8EBCDIC1158RCL8ISOIR111JA16DBCSJA16DBCSFIXED

DK7SIEMENS9780XDK8BS2000E7DECE7SIEMENS9780XE8BS2000EE8BS2000EEC8EUROASCIEEC8EUROPA3EL8DECEL8GCOS7EL8MACGREEKEL8MACGREEKSEL8PC437SEL8PC851ET8MSWIN923F7DECF7SIEMENS9780XF8BS2000HU8ABMODHU8CWI2I7DECI7SIEMENS9780XIN8ISCIIIW7IS960IW8EBCDIC1086US8ICLUTFEVN8VN3WE16DECTSTWE16DECTST2WE8BS2000

JA16EUCFIXEDJA16MACSJISJA16SJISFIXEDKO16DBCSKO16DBCSFIXEDKO16KSC5601FIXEDKO16KSCCSLA8ISO6937LA8PASSPORTLT8PC772LT8PC774LV8PC1117LV8PC8LRLV8RST104090N7SIEMENS9780XNDK7DECNE8ISO8859P10NL7DECS7DECS7SIEMENS9780XS8BS2000SF7ASCIISF7DECTR7DECTR8DECUS16TSTFIXEDUS8BS2000CL8KOI8UD7DECD7SIEMENS9780XD8BS2000

WE8BS2000EWE8BS2000L5WE8DECWE8DECTSTWE8DGWE8EBCDIC924WE8GCOS7WE8HPWE8ICLWE8ISOICLUKWE8NCR4970WE8NEXTSTEPWE8ROMAN8YUG7ASCIIZHS16CGB231280FIXEDZHS16DBCSZHS16DBCSFIXEDZHS16GBKFIXEDZHS16MACCGB231280ZHT16BIG5FIXEDZHT16CCDCZHT16DBCSZHT16DBCSFIXEDZHT16DBTZHT32EUCFIXEDZHT32EUCTSTZHT32SOPSZHT32TRISZHT32TRISFIXED

Territories

Character sets

Linguistic Sorts

ARABIC ARABICARABIC_ABJ_MATCHARABIC_ABJ_SORTARABIC_MATCH

SPANISH SPANISHSPANISH_MXSPANISHGENERIC_M

SIMPLIFIED CHINESE SCHINESE_PINYIN_MSCHINESE_RADICAL_MSCHINESE_STROKE_MGBK

TRADITIONAL CHINESE TCHINESE_RADICAL_MTCHINESE_STROKE_MBIG5HKSCS

Oracle Services

Oracle Locale Mapping Oracle Locale Information Oracle Character Set Conversion Oracle Date, Number, and Monetary

Formatting

Oracle Services cont.

Oracle Binary and Linguistic Sorts including _CI + _AI

Oracle Translated locale and time zone names Oracle Language and Character Set detection

Technology to guess the character set encoding and language of a given byte string or document

D E M O N S T R A T I O N

Oracle Store

Summary

GDK is Oracle’s globalization platform for the middle-tier

– Bring Oracle Globalization features to the J2EE– Reduce Application Development Complexity– Increase Developer Productivity– Decrease Deployment Times– Application Consolidation

Next Steps….

Recommended demos and/or hands-on labs– OW Hands on Session & DEMOgrounds

Globalization Support related questions– Visit the DEMOgrounds for more information.

Relevant web sites to visit for more information

– http://otn.oracle.com/tech/globalization

GDK – 10g and 9i availability

Reminder – please complete the OracleWorld online session survey

Thank you.

AQ&Q U E S T I O N SQ U E S T I O N S

A N S W E R SA N S W E R S