Package com.jk.core.locale
Class JKLocale
java.lang.Object
com.jk.core.locale.JKLocale
- All Implemented Interfaces:
Serializable
The Class JKLocale.
- See Also:
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic JKLocale
Gets the default locale.Gets the direction.int
getId()
Gets the id.getName()
Gets the name.Gets the short name.boolean
Checks if is left to right.static void
setDefaultLocale
(JKLocale defaultLocale) Sets the default locale.void
setDirection
(JKLocaleDirection direction) Sets the direction.void
setId
(int languageId) Sets the id.void
Sets the name.void
setShortName
(String shortName) Sets the short name.toString()
To string.static JKLocale
valueOf
(int languageId) Value of.static JKLocale
Value of.
-
Field Details
-
ARABIC
The Constant ARABIC. -
ENGLISH
The Constant ENGLISH.
-
-
Constructor Details
-
JKLocale
public JKLocale()Instantiates a new JK locale. -
JKLocale
Instantiates a new JK locale.- Parameters:
id
- the idname
- the nameshortName
- the short name
-
JKLocale
Instantiates a new JK locale.- Parameters:
id
- the idname
- the nameshortName
- the short namedirection
- the direction
-
-
Method Details
-
valueOf
Value of.- Parameters:
languageId
- the language id- Returns:
- the JK locale
-
valueOf
Value of.- Parameters:
localeString
- the locale string- Returns:
- the JK locale
-
getId
public int getId()Gets the id.- Returns:
- the id
-
setId
public void setId(int languageId) Sets the id.- Parameters:
languageId
- the new id
-
getName
Gets the name.- Returns:
- the name
-
setName
Sets the name.- Parameters:
languageName
- the new name
-
getShortName
Gets the short name.- Returns:
- the short name
-
setShortName
Sets the short name.- Parameters:
shortName
- the new short name
-
toString
To string. -
setDirection
Sets the direction.- Parameters:
direction
- the new direction
-
getDirection
Gets the direction.- Returns:
- the direction
-
isLeftToRight
public boolean isLeftToRight()Checks if is left to right.- Returns:
- true, if is left to right
-
getDefaultLocale
Gets the default locale.- Returns:
- the default locale
-
setDefaultLocale
Sets the default locale.- Parameters:
defaultLocale
- the new default locale
-