public class AdlLanguage extends AbstractGeneralLanguage
http://www.alexandria.ucsb.edu/gazetteer/protocol/
ALL_WORDS, and, AND, ANY_WORDS, currentClause, currentQuery, EXACT_WORDS, or, OR
Constructor and Description |
---|
AdlLanguage() |
Modifier and Type | Method and Description |
---|---|
String |
addBoundingBox(String coordinates)
It Adds a Bounding Box query
|
void |
addClauses(String parameter,
Iterator values,
String concordancia,
String operator) |
void |
addClauses(String parameter,
String line,
String concordancia,
String option)
It Adds a new clause of the query
|
protected void |
addCurrentClauseQuery(String operator)
It adds the "and" label to join different operations
|
String |
classQuery(String value)
It writes a class-query operator of the ADL language
|
String |
containsPhrase(String value)
It writes a contains-phase operator of the ADL language
|
String |
enterLabel(String pregunta,
String etiqueta)
Envuelve a una pregunta con una etiqueta
|
String |
getOperator(String titleKeys)
Return logic operators
|
String |
switchOperation(String parameter,
String value)
it is used to choose the opeartion.
|
String |
toString()
It returns the encoded query
|
parseValues, parseValues
public void addClauses(String parameter, String line, String concordancia, String option)
value
- Parameter valueparameter
- Parameter nameline
- concordancia
- "E" (Exact phrase), "A" (All words) or "Y" (anY word).option
- operation optionpublic void addClauses(String parameter, Iterator values, String concordancia, String operator)
parameter
- values
- concordancia
- operator
- protected void addCurrentClauseQuery(String operator)
operator
- public String enterLabel(String pregunta, String etiqueta)
pregunta
- Pregunta a envolveretiqueta
- Nombre de la etiquetapublic String toString()
toString
in interface ILanguages
toString
in class Object
public String switchOperation(String parameter, String value)
parameter
- Parameter namevalue
- Parameter valuepublic String containsPhrase(String value)
value
- Toponim valuepublic String classQuery(String value)
value
- Thesaurus valuepublic String addBoundingBox(String coordinates)
coordinates
- Coordinates to findoption
- public String getOperator(String titleKeys)
getOperator
in class AbstractGeneralLanguage
titleKeys
- E,A o Y --> Exact, All, anY