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 |
---|---|
java.lang.String |
addBoundingBox(java.lang.String coordinates)
It Adds a Bounding Box query
|
void |
addClauses(java.lang.String parameter,
java.util.Iterator values,
java.lang.String concordancia,
java.lang.String operator) |
void |
addClauses(java.lang.String parameter,
java.lang.String line,
java.lang.String concordancia,
java.lang.String option)
It Adds a new clause of the query
|
protected void |
addCurrentClauseQuery(java.lang.String operator)
It adds the "and" label to join different operations
|
java.lang.String |
classQuery(java.lang.String value)
It writes a class-query operator of the ADL language
|
java.lang.String |
containsPhrase(java.lang.String value)
It writes a contains-phase operator of the ADL language
|
java.lang.String |
enterLabel(java.lang.String pregunta,
java.lang.String etiqueta)
Envuelve a una pregunta con una etiqueta
|
java.lang.String |
getOperator(java.lang.String titleKeys)
Return logic operators
|
java.lang.String |
switchOperation(java.lang.String parameter,
java.lang.String value)
it is used to choose the opeartion.
|
java.lang.String |
toString()
It returns the encoded query
|
parseValues, parseValues
public void addClauses(java.lang.String parameter, java.lang.String line, java.lang.String concordancia, java.lang.String option)
value
- Parameter valueparameter
- Parameter nameline
- concordancia
- "E" (Exact phrase), "A" (All words) or "Y" (anY word).option
- operation optionpublic void addClauses(java.lang.String parameter, java.util.Iterator values, java.lang.String concordancia, java.lang.String operator)
parameter
- values
- concordancia
- operator
- protected void addCurrentClauseQuery(java.lang.String operator)
operator
- public java.lang.String enterLabel(java.lang.String pregunta, java.lang.String etiqueta)
pregunta
- Pregunta a envolveretiqueta
- Nombre de la etiquetapublic java.lang.String toString()
toString
in interface ILanguages
toString
in class java.lang.Object
public java.lang.String switchOperation(java.lang.String parameter, java.lang.String value)
parameter
- Parameter namevalue
- Parameter valuepublic java.lang.String containsPhrase(java.lang.String value)
value
- Toponim valuepublic java.lang.String classQuery(java.lang.String value)
value
- Thesaurus valuepublic java.lang.String addBoundingBox(java.lang.String coordinates)
coordinates
- Coordinates to findoption
- public java.lang.String getOperator(java.lang.String titleKeys)
getOperator
in class AbstractGeneralLanguage
titleKeys
- E,A o Y --> Exact, All, anY