Documentation ¶
Index ¶
Constants ¶
View Source
const ( // // reserved keywords // SELECT Keyword = iota FACETS SCRIPT FROM WHERE FILTER EXIST MISSING ORDER BY LIMIT AFTER ASC DESC AND OR NOT BETWEEN NO_KEYWORD Keyword = -1 // // operators // EQ Operator = iota NE LT LTE GT GTE OP_AND OP_OR OP_NOT IN OPENP CLOSEP STRING_EXPR EXISTS_EXPR MISSING_EXPR NO_OPERATOR Operator = -1 )
Variables ¶
View Source
var (
Debug = false
)
Functions ¶
Types ¶
type ElseParser ¶
type ElseParser struct { QueryString string // input query string // contains filtered or unexported fields }
func NewParser ¶
func NewParser(queryString string) *ElseParser
func (*ElseParser) Query ¶
func (p *ElseParser) Query() *Query
type ElseSearch ¶
type ElseSearch struct {
// contains filtered or unexported fields
}
func NewClient ¶
func NewClient(endpoint string) *ElseSearch
func (*ElseSearch) AllowInsecure ¶
func (es *ElseSearch) AllowInsecure(insecure bool)
func (*ElseSearch) Search ¶
func (es *ElseSearch) Search(queryString, after, nilValue, index string, returnType ReturnType) (jmap, error)
type Expression ¶
type Expression struct {
// contains filtered or unexported fields
}
func (*Expression) ExistsExpression ¶
func (e *Expression) ExistsExpression() bool
func (*Expression) GetOperand ¶
func (e *Expression) GetOperand() interface{}
func (*Expression) MissingExpression ¶
func (e *Expression) MissingExpression() bool
func (*Expression) QueryString ¶
func (e *Expression) QueryString() string
* Return a query in Lucene syntax
func (*Expression) String ¶
func (e *Expression) String() string
type NameValue ¶
type NameValue struct { Name string Value interface{} }
func (NameValue) QueryString ¶
type ParseError ¶
type ParseError string
* Parse error
func (ParseError) Error ¶
func (e ParseError) Error() string
type Query ¶
type Query struct { SelectList []string FacetList []string Index string WhereExpr *Expression FilterExpr *Expression Script *NameValue OrderList []NameValue From int Size int After string }
* This is the output of a parsed statement
type SearchError ¶
func (SearchError) Error ¶
func (e SearchError) Error() string
Click to show internal directories.
Click to hide internal directories.