|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.tudarmstadt.ukp.jwktl.api.util.Language
public class Language
Implementation of the ILanguage
interface. This class should
not be instanciated by yourself. Use the static methods to find registered
instances - either by language code or name.
Field Summary | |
---|---|
protected String |
code
|
static ILanguage |
ENGLISH
The English language. |
static ILanguage |
GERMAN
The German language. |
protected String |
iso639_1
|
protected String |
iso639_2b
|
protected String |
iso639_2t
|
protected String |
iso639_3
|
protected String |
name
|
static ILanguage |
RUSSIAN
The Russian language. |
Constructor Summary | |
---|---|
protected |
Language(String code,
String name,
String iso639_3,
String iso639_2b,
String iso639_2t,
String iso639_1)
|
Method Summary | |
---|---|
int |
compareTo(ILanguage other)
|
static boolean |
equals(ILanguage language1,
ILanguage language2)
Tests if the specified languages are equal. |
boolean |
equals(Object other)
|
static ILanguage |
findByCode(String code)
Find the language with the given code. |
static ILanguage |
findByName(String name)
Find the language with the given name. |
static ILanguage |
get(String code)
Returns the language with the given internal code. |
String |
getCode()
Returns the internal language code used by JWTKL. |
String |
getISO639_1()
Returns the ISO 639-1 code or an empty string if none. |
String |
getISO639_2B()
Returns the ISO 639-2b code or an empty string if none. |
String |
getISO639_2T()
Returns the ISO 639-2t code or an empty string if none. |
String |
getISO639_3()
Returns the ISO 639-3 code or an empty string if none. |
String |
getName()
Returns the language name (in English language). |
int |
hashCode()
|
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected String code
protected String name
protected String iso639_3
protected String iso639_2b
protected String iso639_2t
protected String iso639_1
public static final ILanguage ENGLISH
public static final ILanguage GERMAN
public static final ILanguage RUSSIAN
Constructor Detail |
---|
protected Language(String code, String name, String iso639_3, String iso639_2b, String iso639_2t, String iso639_1)
Method Detail |
---|
public String getCode()
ILanguage
getCode
in interface ILanguage
public String getName()
ILanguage
getName
in interface ILanguage
public String getISO639_3()
ILanguage
getISO639_3
in interface ILanguage
public String getISO639_2B()
ILanguage
getISO639_2B
in interface ILanguage
public String getISO639_2T()
ILanguage
getISO639_2T
in interface ILanguage
public String getISO639_1()
ILanguage
getISO639_1
in interface ILanguage
public int compareTo(ILanguage other)
compareTo
in interface Comparable<ILanguage>
public boolean equals(Object other)
equals
in class Object
public int hashCode()
hashCode
in class Object
public String toString()
toString
in class Object
public static ILanguage get(String code)
findByCode(String)
if you are
unsure about your code. If no language could be found,
null
is returned.
public static ILanguage findByCode(String code)
null
is returned.
public static ILanguage findByName(String name)
null
is returned.
public static boolean equals(ILanguage language1, ILanguage language2)
true
if both languages are null
, but
false
if only one of them is null
.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |