|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectmain.QueryDescription
public class QueryDescription
The QueryDescription class parses the input file query given
to it by the InputFileParser and provides methods for
extracting the query sections of the file.
| Field Summary | |
|---|---|
private int |
DEFAULT_TIMEOUT
|
private java.lang.String |
query
|
private java.util.ArrayList<QueryVariable> |
querySpecifications
|
private int |
queryTimeout
|
| Constructor Summary | |
|---|---|
QueryDescription(java.lang.String inputFileQuery)
Creates a new QueryDescription given an input file query
from the InputFileParser. |
|
| Method Summary | |
|---|---|
java.lang.String |
getQuery()
Returns a new query generated from the specifications or null if none was specified. |
QueryVariable[] |
getQueryVariables()
Returns the QueryVariables for the query or null if none
were specified. |
int |
getTimeout()
Returns the timeout value for the query, or null if none was specified. |
private void |
parseInput(java.lang.String inputFileQuery)
|
(package private) QueryVariable |
parseVariableSpecification(java.lang.String line)
|
void |
setTimeout(int timeout)
Sets the query timeout. |
void |
setVariable(java.lang.String variableName,
java.lang.String variableValue)
Sets a query variable to a new value. |
java.lang.String |
toString()
Returns a string representation of this QueryDescription. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
private java.lang.String query
private int queryTimeout
private java.util.ArrayList<QueryVariable> querySpecifications
private final int DEFAULT_TIMEOUT
| Constructor Detail |
|---|
public QueryDescription(java.lang.String inputFileQuery)
throws java.text.ParseException
QueryDescription given an input file query
from the InputFileParser.
inputFileQuery - a String
java.text.ParseException - if a parse error occurs| Method Detail |
|---|
private void parseInput(java.lang.String inputFileQuery)
throws java.text.ParseException
java.text.ParseException
QueryVariable parseVariableSpecification(java.lang.String line)
throws java.text.ParseException
java.text.ParseExceptionpublic java.lang.String getQuery()
public int getTimeout()
public void setTimeout(int timeout)
timeout - an int
public void setVariable(java.lang.String variableName,
java.lang.String variableValue)
throws javax.naming.directory.InvalidAttributeIdentifierException
variableName - a StringvariableValue - a String
javax.naming.directory.InvalidAttributeIdentifierException - if the attribute with the given name does not existpublic QueryVariable[] getQueryVariables()
QueryVariables for the query or null if none
were specified.
public java.lang.String toString()
QueryDescription.
This is for debugging purposes only.
toString in class java.lang.ObjectQueryDescroption
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||