|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.atlassian.confluence.search.v2.QuerySerializer
public class QuerySerializer
Responsible for converting SearchQueries to and from their String form.
| Constructor Summary | |
|---|---|
QuerySerializer(QueryFactory queryFactory)
Construct a new query serializer |
|
| Method Summary | |
|---|---|
protected static java.lang.String |
escape(java.lang.String s)
Escape any double-quote in a string with a backslash, and any backslash with a second backslash. |
static java.lang.String |
queryToString(SearchQuery query)
Convert a SearchQuery into a string form that can be transported over the wire, saved, and so on |
SearchQuery |
stringToQuery(java.lang.String s)
Convert a string-form query back into object form. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public QuerySerializer(QueryFactory queryFactory)
queryFactory - the factory to convert SearchQuery string keys back into query objects| Method Detail |
|---|
public static java.lang.String queryToString(SearchQuery query)
query - the query to convert
public SearchQuery stringToQuery(java.lang.String s)
throws InvalidQueryException
All clients of the serializer must be able to recover from both of the above circumstances safely.
s - the string to convert
InvalidQueryException - if the string could not be converted successfullyprotected static java.lang.String escape(java.lang.String s)
s - the string to quote
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||