public abstract class XContentStructure extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
XContentStructure
InnerFilter is an extension of
XContentStructure that eagerly parses the filter in a streaming manner if the types are available at construction time.
|
static class |
XContentStructure
InnerQuery is an extension of
XContentStructure that eagerly parses the query in a streaming manner if the types are available at construction time.
|
| Constructor and Description |
|---|
XContentStructure(QueryParseContext
Create a new XContentStructure for the current parsing context.
|
| Modifier and Type | Method and Description |
|---|---|
org |
asFilter(String
Use the captured bytes to parse the inner filter using the specified types.
|
org |
asQuery(String
Use the captured bytes to parse the inner query using the specified types.
|
BytesReference |
bytes()
Return the bytes that are going to be used for parsing
|
void |
bytes(BytesReference
Set the bytes to be used for parsing
|
XContentStructure |
freeze()
"Freeze" the parsing content, which means copying the current parser's structure into an internal
BytesReference to be parsed later.
|
public XContentStructure(QueryParseContextqueryParseContext)
public XContentStructurefreeze() throws IOException
BytesReference to be parsed later.
IOException
public void bytes(BytesReferenceinnerBytes)
public BytesReferencebytes()
public org.apache .lucene .search .Query asQuery(String ... types) throws IOException
types - types to be used during the inner query parsing
Query parsed from the bytes captured in
freeze()
IOException
public org.apache .lucene .search .Query asFilter(String ... types) throws IOException
types - types to be used during the inner filter parsing
XConstantScoreQuery wrapping the filter parsed from the bytes captured in
freeze()
IOException