Class JKLocale

java.lang.Object
com.jk.core.locale.JKLocale
All Implemented Interfaces:
Serializable

public class JKLocale extends Object implements Serializable
The Class JKLocale.
See Also:
  • Field Details

    • ARABIC

      public static final JKLocale ARABIC
      The Constant ARABIC.
    • ENGLISH

      public static final JKLocale ENGLISH
      The Constant ENGLISH.
  • Constructor Details

    • JKLocale

      public JKLocale()
      Instantiates a new JK locale.
    • JKLocale

      public JKLocale(int id, String name, String shortName)
      Instantiates a new JK locale.
      Parameters:
      id - the id
      name - the name
      shortName - the short name
    • JKLocale

      public JKLocale(int id, String name, String shortName, JKLocaleDirection direction)
      Instantiates a new JK locale.
      Parameters:
      id - the id
      name - the name
      shortName - the short name
      direction - the direction
  • Method Details

    • valueOf

      public static JKLocale valueOf(int languageId)
      Value of.
      Parameters:
      languageId - the language id
      Returns:
      the JK locale
    • valueOf

      public static JKLocale valueOf(String localeString)
      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

      public String getName()
      Gets the name.
      Returns:
      the name
    • setName

      public void setName(String languageName)
      Sets the name.
      Parameters:
      languageName - the new name
    • getShortName

      public String getShortName()
      Gets the short name.
      Returns:
      the short name
    • setShortName

      public void setShortName(String shortName)
      Sets the short name.
      Parameters:
      shortName - the new short name
    • toString

      public String toString()
      To string.
      Overrides:
      toString in class Object
      Returns:
      the string
    • setDirection

      public void setDirection(JKLocaleDirection direction)
      Sets the direction.
      Parameters:
      direction - the new direction
    • getDirection

      public JKLocaleDirection 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

      public static JKLocale getDefaultLocale()
      Gets the default locale.
      Returns:
      the default locale
    • setDefaultLocale

      public static void setDefaultLocale(JKLocale defaultLocale)
      Sets the default locale.
      Parameters:
      defaultLocale - the new default locale