go-appbase: github.com/appbaseio/go-appbase/actions Index | Files

package actions

import "github.com/appbaseio/go-appbase/actions"

Index

Package Files

delete.go get.go get_stream.go index.go search.go search_aggs.go search_stream.go search_stream_to_url.go update.go validate.go

type Aggregation Uses

type Aggregation interface {
    // Source returns a JSON-serializable aggregation that is a fragment
    // of the request sent to Elasticsearch.
    Source() (interface{}, error)
}

Aggregations can be seen as a unit-of-work that build analytic information over a set of documents. It is (in many senses) the follow-up of facets in Elasticsearch. For more details about aggregations, visit: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations.html

type AggregationBucketFilters Uses

type AggregationBucketFilters struct {
    Aggregations

    Buckets      []*AggregationBucketKeyItem          //`json:"buckets"`
    NamedBuckets map[string]*AggregationBucketKeyItem //`json:"buckets"`
    Meta         map[string]interface{}               // `json:"meta,omitempty"`
}

AggregationBucketFilters is a multi-bucket aggregation that is returned with a filters aggregation.

func (*AggregationBucketFilters) UnmarshalJSON Uses

func (a *AggregationBucketFilters) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationBucketFilters structure.

type AggregationBucketHistogramItem Uses

type AggregationBucketHistogramItem struct {
    Aggregations

    Key         int64   //`json:"key"`
    KeyAsString *string //`json:"key_as_string"`
    DocCount    int64   //`json:"doc_count"`
}

AggregationBucketHistogramItem is a single bucket of an AggregationBucketHistogramItems structure.

func (*AggregationBucketHistogramItem) UnmarshalJSON Uses

func (a *AggregationBucketHistogramItem) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationBucketHistogramItem structure.

type AggregationBucketHistogramItems Uses

type AggregationBucketHistogramItems struct {
    Aggregations

    Buckets []*AggregationBucketHistogramItem //`json:"buckets"`
    Meta    map[string]interface{}            // `json:"meta,omitempty"`
}

AggregationBucketHistogramItems is a bucket aggregation that is returned with a date histogram aggregation.

func (*AggregationBucketHistogramItems) UnmarshalJSON Uses

func (a *AggregationBucketHistogramItems) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationBucketHistogramItems structure.

type AggregationBucketKeyItem Uses

type AggregationBucketKeyItem struct {
    Aggregations

    Key       interface{} //`json:"key"`
    KeyNumber json.Number
    DocCount  int64 //`json:"doc_count"`
}

AggregationBucketKeyItem is a single bucket of an AggregationBucketKeyItems structure.

func (*AggregationBucketKeyItem) UnmarshalJSON Uses

func (a *AggregationBucketKeyItem) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationBucketKeyItem structure.

type AggregationBucketKeyItems Uses

type AggregationBucketKeyItems struct {
    Aggregations

    DocCountErrorUpperBound int64                       //`json:"doc_count_error_upper_bound"`
    SumOfOtherDocCount      int64                       //`json:"sum_other_doc_count"`
    Buckets                 []*AggregationBucketKeyItem //`json:"buckets"`
    Meta                    map[string]interface{}      // `json:"meta,omitempty"`
}

AggregationBucketKeyItems is a bucket aggregation that is e.g. returned with a terms aggregation.

func (*AggregationBucketKeyItems) UnmarshalJSON Uses

func (a *AggregationBucketKeyItems) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationBucketKeyItems structure.

type AggregationBucketKeyedRangeItems Uses

type AggregationBucketKeyedRangeItems struct {
    Aggregations

    DocCountErrorUpperBound int64                                  //`json:"doc_count_error_upper_bound"`
    SumOfOtherDocCount      int64                                  //`json:"sum_other_doc_count"`
    Buckets                 map[string]*AggregationBucketRangeItem //`json:"buckets"`
    Meta                    map[string]interface{}                 // `json:"meta,omitempty"`
}

AggregationBucketKeyedRangeItems is a bucket aggregation that is e.g. returned with a keyed range aggregation.

func (*AggregationBucketKeyedRangeItems) UnmarshalJSON Uses

func (a *AggregationBucketKeyedRangeItems) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationBucketRangeItems structure.

type AggregationBucketRangeItem Uses

type AggregationBucketRangeItem struct {
    Aggregations

    Key          string   //`json:"key"`
    DocCount     int64    //`json:"doc_count"`
    From         *float64 //`json:"from"`
    FromAsString string   //`json:"from_as_string"`
    To           *float64 //`json:"to"`
    ToAsString   string   //`json:"to_as_string"`
}

AggregationBucketRangeItem is a single bucket of an AggregationBucketRangeItems structure.

func (*AggregationBucketRangeItem) UnmarshalJSON Uses

func (a *AggregationBucketRangeItem) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationBucketRangeItem structure.

type AggregationBucketRangeItems Uses

type AggregationBucketRangeItems struct {
    Aggregations

    DocCountErrorUpperBound int64                         //`json:"doc_count_error_upper_bound"`
    SumOfOtherDocCount      int64                         //`json:"sum_other_doc_count"`
    Buckets                 []*AggregationBucketRangeItem //`json:"buckets"`
    Meta                    map[string]interface{}        // `json:"meta,omitempty"`
}

AggregationBucketRangeItems is a bucket aggregation that is e.g. returned with a range aggregation.

func (*AggregationBucketRangeItems) UnmarshalJSON Uses

func (a *AggregationBucketRangeItems) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationBucketRangeItems structure.

type AggregationBucketSignificantTerm Uses

type AggregationBucketSignificantTerm struct {
    Aggregations

    Key      string  //`json:"key"`
    DocCount int64   //`json:"doc_count"`
    BgCount  int64   //`json:"bg_count"`
    Score    float64 //`json:"score"`
}

AggregationBucketSignificantTerm is a single bucket of an AggregationBucketSignificantTerms structure.

func (*AggregationBucketSignificantTerm) UnmarshalJSON Uses

func (a *AggregationBucketSignificantTerm) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationBucketSignificantTerm structure.

type AggregationBucketSignificantTerms Uses

type AggregationBucketSignificantTerms struct {
    Aggregations

    DocCount int64                               //`json:"doc_count"`
    Buckets  []*AggregationBucketSignificantTerm //`json:"buckets"`
    Meta     map[string]interface{}              // `json:"meta,omitempty"`
}

AggregationBucketSignificantTerms is a bucket aggregation returned with a significant terms aggregation.

func (*AggregationBucketSignificantTerms) UnmarshalJSON Uses

func (a *AggregationBucketSignificantTerms) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationBucketSignificantTerms structure.

type AggregationExtendedStatsMetric Uses

type AggregationExtendedStatsMetric struct {
    Aggregations

    Count        int64                  // `json:"count"`
    Min          *float64               //`json:"min,omitempty"`
    Max          *float64               //`json:"max,omitempty"`
    Avg          *float64               //`json:"avg,omitempty"`
    Sum          *float64               //`json:"sum,omitempty"`
    SumOfSquares *float64               //`json:"sum_of_squares,omitempty"`
    Variance     *float64               //`json:"variance,omitempty"`
    StdDeviation *float64               //`json:"std_deviation,omitempty"`
    Meta         map[string]interface{} // `json:"meta,omitempty"`
}

AggregationExtendedStatsMetric is a multi-value metric, returned by an ExtendedStats aggregation.

func (*AggregationExtendedStatsMetric) UnmarshalJSON Uses

func (a *AggregationExtendedStatsMetric) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationExtendedStatsMetric structure.

type AggregationGeoBoundsMetric Uses

type AggregationGeoBoundsMetric struct {
    Aggregations

    Bounds struct {
        TopLeft struct {
            Latitude  float64 `json:"lat"`
            Longitude float64 `json:"lon"`
        }   `json:"top_left"`
        BottomRight struct {
            Latitude  float64 `json:"lat"`
            Longitude float64 `json:"lon"`
        }   `json:"bottom_right"`
    }   `json:"bounds"`

    Meta map[string]interface{} // `json:"meta,omitempty"`
}

AggregationGeoBoundsMetric is a metric as returned by a GeoBounds aggregation.

func (*AggregationGeoBoundsMetric) UnmarshalJSON Uses

func (a *AggregationGeoBoundsMetric) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationGeoBoundsMetric structure.

type AggregationPercentilesMetric Uses

type AggregationPercentilesMetric struct {
    Aggregations

    Values map[string]float64     // `json:"values"`
    Meta   map[string]interface{} // `json:"meta,omitempty"`
}

AggregationPercentilesMetric is a multi-value metric, returned by a Percentiles aggregation.

func (*AggregationPercentilesMetric) UnmarshalJSON Uses

func (a *AggregationPercentilesMetric) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationPercentilesMetric structure.

type AggregationPipelineBucketMetricValue Uses

type AggregationPipelineBucketMetricValue struct {
    Aggregations

    Keys          []interface{}          // `json:"keys"`
    Value         *float64               // `json:"value"`
    ValueAsString string                 // `json:"value_as_string"`
    Meta          map[string]interface{} // `json:"meta,omitempty"`
}

AggregationPipelineBucketMetricValue is a value returned e.g. by a MaxBucket aggregation.

func (*AggregationPipelineBucketMetricValue) UnmarshalJSON Uses

func (a *AggregationPipelineBucketMetricValue) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationPipelineBucketMetricValue structure.

type AggregationPipelineDerivative Uses

type AggregationPipelineDerivative struct {
    Aggregations

    Value                   *float64               // `json:"value"`
    ValueAsString           string                 // `json:"value_as_string"`
    NormalizedValue         *float64               // `json:"normalized_value"`
    NormalizedValueAsString string                 // `json:"normalized_value_as_string"`
    Meta                    map[string]interface{} // `json:"meta,omitempty"`
}

AggregationPipelineDerivative is the value returned by a Derivative aggregation.

func (*AggregationPipelineDerivative) UnmarshalJSON Uses

func (a *AggregationPipelineDerivative) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationPipelineDerivative structure.

type AggregationPipelineSimpleValue Uses

type AggregationPipelineSimpleValue struct {
    Aggregations

    Value         *float64               // `json:"value"`
    ValueAsString string                 // `json:"value_as_string"`
    Meta          map[string]interface{} // `json:"meta,omitempty"`
}

AggregationPipelineSimpleValue is a simple value, returned e.g. by a MovAvg aggregation.

func (*AggregationPipelineSimpleValue) UnmarshalJSON Uses

func (a *AggregationPipelineSimpleValue) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationPipelineSimpleValue structure.

type AggregationSingleBucket Uses

type AggregationSingleBucket struct {
    Aggregations

    DocCount int64                  // `json:"doc_count"`
    Meta     map[string]interface{} // `json:"meta,omitempty"`
}

AggregationSingleBucket is a single bucket, returned e.g. via an aggregation of type Global.

func (*AggregationSingleBucket) UnmarshalJSON Uses

func (a *AggregationSingleBucket) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationSingleBucket structure.

type AggregationStatsMetric Uses

type AggregationStatsMetric struct {
    Aggregations

    Count int64                  // `json:"count"`
    Min   *float64               //`json:"min,omitempty"`
    Max   *float64               //`json:"max,omitempty"`
    Avg   *float64               //`json:"avg,omitempty"`
    Sum   *float64               //`json:"sum,omitempty"`
    Meta  map[string]interface{} // `json:"meta,omitempty"`
}

AggregationStatsMetric is a multi-value metric, returned by a Stats aggregation.

func (*AggregationStatsMetric) UnmarshalJSON Uses

func (a *AggregationStatsMetric) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationStatsMetric structure.

type AggregationTopHitsMetric Uses

type AggregationTopHitsMetric struct {
    Aggregations

    Hits *SearchHits            //`json:"hits"`
    Meta map[string]interface{} // `json:"meta,omitempty"`
}

AggregationTopHitsMetric is a metric returned by a TopHits aggregation.

func (*AggregationTopHitsMetric) UnmarshalJSON Uses

func (a *AggregationTopHitsMetric) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationTopHitsMetric structure.

type AggregationValueMetric Uses

type AggregationValueMetric struct {
    Aggregations

    Value *float64               //`json:"value"`
    Meta  map[string]interface{} // `json:"meta,omitempty"`
}

AggregationValueMetric is a single-value metric, returned e.g. by a Min or Max aggregation.

func (*AggregationValueMetric) UnmarshalJSON Uses

func (a *AggregationValueMetric) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data and initializes an AggregationValueMetric structure.

type Aggregations Uses

type Aggregations map[string]*json.RawMessage

Aggregations is a list of aggregations that are part of a search result.

func (Aggregations) Avg Uses

func (a Aggregations) Avg(name string) (*AggregationValueMetric, bool)

Avg returns average aggregation results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-metrics-avg-aggregation.html

func (Aggregations) AvgBucket Uses

func (a Aggregations) AvgBucket(name string) (*AggregationPipelineSimpleValue, bool)

AvgBucket returns average bucket pipeline aggregation results. See https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-pipeline-avg-bucket-aggregation.html

func (Aggregations) BucketScript Uses

func (a Aggregations) BucketScript(name string) (*AggregationPipelineSimpleValue, bool)

BucketScript returns bucket script pipeline aggregation results. See https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-pipeline-bucket-script-aggregation.html

func (Aggregations) Cardinality Uses

func (a Aggregations) Cardinality(name string) (*AggregationValueMetric, bool)

Cardinality returns cardinality aggregation results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-metrics-cardinality-aggregation.html

func (Aggregations) Children Uses

func (a Aggregations) Children(name string) (*AggregationSingleBucket, bool)

Children returns children results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-bucket-children-aggregation.html

func (Aggregations) CumulativeSum Uses

func (a Aggregations) CumulativeSum(name string) (*AggregationPipelineSimpleValue, bool)

CumulativeSum returns a cumulative sum pipeline aggregation results. See https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-pipeline-cumulative-sum-aggregation.html

func (Aggregations) DateHistogram Uses

func (a Aggregations) DateHistogram(name string) (*AggregationBucketHistogramItems, bool)

DateHistogram returns date histogram aggregation results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-bucket-datehistogram-aggregation.html

func (Aggregations) DateRange Uses

func (a Aggregations) DateRange(name string) (*AggregationBucketRangeItems, bool)

DateRange returns date range aggregation results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-bucket-daterange-aggregation.html

func (Aggregations) Derivative Uses

func (a Aggregations) Derivative(name string) (*AggregationPipelineDerivative, bool)

Derivative returns derivative pipeline aggregation results. See https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-pipeline-derivative-aggregation.html

func (Aggregations) ExtendedStats Uses

func (a Aggregations) ExtendedStats(name string) (*AggregationExtendedStatsMetric, bool)

ExtendedStats returns extended stats aggregation results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-metrics-extendedstats-aggregation.html

func (Aggregations) Filter Uses

func (a Aggregations) Filter(name string) (*AggregationSingleBucket, bool)

Filter returns filter results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-bucket-filter-aggregation.html

func (Aggregations) Filters Uses

func (a Aggregations) Filters(name string) (*AggregationBucketFilters, bool)

Filters returns filters results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-bucket-filters-aggregation.html

func (Aggregations) GeoBounds Uses

func (a Aggregations) GeoBounds(name string) (*AggregationGeoBoundsMetric, bool)

GeoBounds returns geo-bounds aggregation results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-metrics-geobounds-aggregation.html

func (Aggregations) GeoDistance Uses

func (a Aggregations) GeoDistance(name string) (*AggregationBucketRangeItems, bool)

GeoDistance returns geo distance aggregation results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-bucket-geodistance-aggregation.html

func (Aggregations) GeoHash Uses

func (a Aggregations) GeoHash(name string) (*AggregationBucketKeyItems, bool)

GeoHash returns geo-hash aggregation results. http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-bucket-geohashgrid-aggregation.html

func (Aggregations) Global Uses

func (a Aggregations) Global(name string) (*AggregationSingleBucket, bool)

Global returns global results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-bucket-global-aggregation.html

func (Aggregations) Histogram Uses

func (a Aggregations) Histogram(name string) (*AggregationBucketHistogramItems, bool)

Histogram returns histogram aggregation results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-bucket-histogram-aggregation.html

func (Aggregations) IPv4Range Uses

func (a Aggregations) IPv4Range(name string) (*AggregationBucketRangeItems, bool)

IPv4Range returns IPv4 range aggregation results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-bucket-iprange-aggregation.html

func (Aggregations) KeyedRange Uses

func (a Aggregations) KeyedRange(name string) (*AggregationBucketKeyedRangeItems, bool)

KeyedRange returns keyed range aggregation results. See http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-bucket-range-aggregation.html.

func (Aggregations) Max Uses

func (a Aggregations) Max(name string) (*AggregationValueMetric, bool)

Max returns max aggregation results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-metrics-max-aggregation.html

func (Aggregations) MaxBucket Uses

func (a Aggregations) MaxBucket(name string) (*AggregationPipelineBucketMetricValue, bool)

MaxBucket returns maximum bucket pipeline aggregation results. See https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-pipeline-max-bucket-aggregation.html

func (Aggregations) Min Uses

func (a Aggregations) Min(name string) (*AggregationValueMetric, bool)

Min returns min aggregation results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-metrics-min-aggregation.html

func (Aggregations) MinBucket Uses

func (a Aggregations) MinBucket(name string) (*AggregationPipelineBucketMetricValue, bool)

MinBucket returns minimum bucket pipeline aggregation results. See https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-pipeline-min-bucket-aggregation.html

func (Aggregations) Missing Uses

func (a Aggregations) Missing(name string) (*AggregationSingleBucket, bool)

Missing returns missing results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-bucket-missing-aggregation.html

func (Aggregations) MovAvg Uses

func (a Aggregations) MovAvg(name string) (*AggregationPipelineSimpleValue, bool)

MovAvg returns moving average pipeline aggregation results. See https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-pipeline-movavg-aggregation.html

func (Aggregations) Nested Uses

func (a Aggregations) Nested(name string) (*AggregationSingleBucket, bool)

Nested returns nested results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-bucket-nested-aggregation.html

func (Aggregations) PercentileRanks Uses

func (a Aggregations) PercentileRanks(name string) (*AggregationPercentilesMetric, bool)

PercentileRanks returns percentile ranks results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-metrics-percentile-rank-aggregation.html

func (Aggregations) Percentiles Uses

func (a Aggregations) Percentiles(name string) (*AggregationPercentilesMetric, bool)

Percentiles returns percentiles results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-metrics-percentile-aggregation.html

func (Aggregations) Range Uses

func (a Aggregations) Range(name string) (*AggregationBucketRangeItems, bool)

Range returns range aggregation results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-bucket-range-aggregation.html

func (Aggregations) ReverseNested Uses

func (a Aggregations) ReverseNested(name string) (*AggregationSingleBucket, bool)

ReverseNested returns reverse-nested results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-bucket-reverse-nested-aggregation.html

func (Aggregations) SerialDiff Uses

func (a Aggregations) SerialDiff(name string) (*AggregationPipelineSimpleValue, bool)

SerialDiff returns serial differencing pipeline aggregation results. See https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-pipeline-serialdiff-aggregation.html

func (Aggregations) SignificantTerms Uses

func (a Aggregations) SignificantTerms(name string) (*AggregationBucketSignificantTerms, bool)

SignificantTerms returns significant terms aggregation results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-bucket-significantterms-aggregation.html

func (Aggregations) Stats Uses

func (a Aggregations) Stats(name string) (*AggregationStatsMetric, bool)

Stats returns stats aggregation results. http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-metrics-stats-aggregation.html

func (Aggregations) Sum Uses

func (a Aggregations) Sum(name string) (*AggregationValueMetric, bool)

Sum returns sum aggregation results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-metrics-sum-aggregation.html

func (Aggregations) SumBucket Uses

func (a Aggregations) SumBucket(name string) (*AggregationPipelineSimpleValue, bool)

SumBucket returns sum bucket pipeline aggregation results. See https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-pipeline-sum-bucket-aggregation.html

func (Aggregations) Terms Uses

func (a Aggregations) Terms(name string) (*AggregationBucketKeyItems, bool)

Terms returns terms aggregation results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-bucket-terms-aggregation.html

func (Aggregations) TopHits Uses

func (a Aggregations) TopHits(name string) (*AggregationTopHitsMetric, bool)

TopHits returns top-hits aggregation results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-metrics-top-hits-aggregation.html

func (Aggregations) ValueCount Uses

func (a Aggregations) ValueCount(name string) (*AggregationValueMetric, bool)

ValueCount returns value-count aggregation results. See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-aggregations-metrics-valuecount-aggregation.html

type DeleteResponse Uses

type DeleteResponse struct {
    Index   string `json:"_index"`   // index meta field
    Type    string `json:"_type"`    // type meta field
    Id      string `json:"_id"`      // id meta field
    Version int64  `json:"_version"` // version number, when Version is set to true in SearchService
    Found   bool   `json:"found,omitempty"`
}

type DeleteService Uses

type DeleteService struct {
    // contains filtered or unexported fields
}

func NewDeleteService Uses

func NewDeleteService(conn *connection.Connection) *DeleteService

func (*DeleteService) Do Uses

func (d *DeleteService) Do() (*DeleteResponse, error)

func (*DeleteService) Id Uses

func (d *DeleteService) Id(_id string) *DeleteService

func (*DeleteService) Type Uses

func (d *DeleteService) Type(_type string) *DeleteService

func (*DeleteService) URLParams Uses

func (d *DeleteService) URLParams(params url.Values) *DeleteService

type DeleteServiceOptions Uses

type DeleteServiceOptions struct {
    Type   string `validate:"required"`
    Id     string `validate:"required"`
    Params url.Values
}

type GetResponse Uses

type GetResponse struct {
    Index   string                 `json:"_index"`   // index meta field
    Type    string                 `json:"_type"`    // type meta field
    Id      string                 `json:"_id"`      // id meta field
    Parent  string                 `json:"_parent"`  // parent meta field
    Version int64                  `json:"_version"` // version number, when Version is set to true in SearchService
    Source  *json.RawMessage       `json:"_source,omitempty"`
    Found   bool                   `json:"found,omitempty"`
    Fields  map[string]interface{} `json:"fields,omitempty"`
}

type GetService Uses

type GetService struct {
    // contains filtered or unexported fields
}

func NewGetService Uses

func NewGetService(conn *connection.Connection) *GetService

func (*GetService) Do Uses

func (g *GetService) Do() (*GetResponse, error)

func (*GetService) Id Uses

func (g *GetService) Id(_id string) *GetService

func (*GetService) Type Uses

func (g *GetService) Type(_type string) *GetService

func (*GetService) URLParams Uses

func (g *GetService) URLParams(params url.Values) *GetService

type GetServiceOptions Uses

type GetServiceOptions struct {
    Type   string `validate:"required"`
    Id     string `validate:"required"`
    Params url.Values
}

type GetStreamResponse Uses

type GetStreamResponse struct {
    // contains filtered or unexported fields
}

func (*GetStreamResponse) Next Uses

func (g *GetStreamResponse) Next() (getResponse *GetResponse, err error)

type GetStreamService Uses

type GetStreamService struct {
    GetService
}

func NewGetStreamService Uses

func NewGetStreamService(conn *connection.Connection) *GetStreamService

func (*GetStreamService) Do Uses

func (g *GetStreamService) Do() (*GetStreamResponse, error)

func (*GetStreamService) Id Uses

func (g *GetStreamService) Id(_id string) *GetStreamService

func (*GetStreamService) Type Uses

func (g *GetStreamService) Type(_type string) *GetStreamService

func (*GetStreamService) URLParams Uses

func (g *GetStreamService) URLParams(params url.Values) *GetStreamService

type IndexResponse Uses

type IndexResponse struct {
    Index   string `json:"_index"`
    Type    string `json:"_type"`
    Id      string `json:"_id"`
    Version int    `json:"_version"`
    Created bool   `json:"created"`
}

type IndexService Uses

type IndexService struct {
    // contains filtered or unexported fields
}

func NewIndexService Uses

func NewIndexService(conn *connection.Connection) *IndexService

func (*IndexService) Body Uses

func (i *IndexService) Body(body string) *IndexService

func (*IndexService) Do Uses

func (i *IndexService) Do() (*IndexResponse, error)

func (*IndexService) Id Uses

func (i *IndexService) Id(_id string) *IndexService

func (*IndexService) Type Uses

func (i *IndexService) Type(_type string) *IndexService

func (*IndexService) URLParams Uses

func (i *IndexService) URLParams(params url.Values) *IndexService

type IndexServiceOptions Uses

type IndexServiceOptions struct {
    Type   string `validate:"required"`
    Id     string
    Body   string `validate:"required"`
    Params url.Values
}

type SearchExplanation Uses

type SearchExplanation struct {
    Value       float64             `json:"value"`             // e.s. 1.0
    Description string              `json:"description"`       // e.s. "boost" or "ConstantScore(*:*), product of:"
    Details     []SearchExplanation `json:"details,omitempty"` // recursive details
}

SearchExplanation explains how the score for a hit was computed. See http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-request-explain.html.

type SearchHit Uses

type SearchHit struct {
    Score          *float64                       `json:"_score"`          // computed score
    Index          string                         `json:"_index"`          // index name
    Type           string                         `json:"_type"`           // type meta field
    Id             string                         `json:"_id"`             // external or internal
    Uid            string                         `json:"_uid"`            // uid meta field (see MapperService.java for all meta fields)
    Timestamp      int64                          `json:"_timestamp"`      // timestamp meta field
    TTL            int64                          `json:"_ttl"`            // ttl meta field
    Routing        string                         `json:"_routing"`        // routing meta field
    Parent         string                         `json:"_parent"`         // parent meta field
    Version        *int64                         `json:"_version"`        // version number, when Version is set to true in SearchService
    Sort           []interface{}                  `json:"sort"`            // sort information
    Highlight      SearchHitHighlight             `json:"highlight"`       // highlighter information
    Source         *json.RawMessage               `json:"_source"`         // stored document source
    Fields         map[string]interface{}         `json:"fields"`          // returned fields
    Explanation    *SearchExplanation             `json:"_explanation"`    // explains how the score was computed
    MatchedQueries []string                       `json:"matched_queries"` // matched queries
    InnerHits      map[string]*SearchHitInnerHits `json:"inner_hits"`      // inner hits with ES >= 1.5.0
}

SearchHit is a single hit.

type SearchHitHighlight Uses

type SearchHitHighlight map[string][]string

Highlighting SearchHitHighlight is the highlight information of a search hit. See http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-request-highlightins.html for a general discussion of highlightins.

type SearchHitInnerHits Uses

type SearchHitInnerHits struct {
    Hits *SearchHits `json:"hits"`
}

type SearchHits Uses

type SearchHits struct {
    TotalHits int64        `json:"total"`     // total number of hits found
    MaxScore  *float64     `json:"max_score"` // maximum score of all hits
    Hits      []*SearchHit `json:"hits"`      // the actual hits returned
}

SearchResponse specifies the list of search hits.

type SearchResponse Uses

type SearchResponse struct {
    TookInMillis int64         `json:"took"`         // search time in milliseconds
    ScrollId     string        `json:"_scroll_id"`   // only used with Scroll and Scan operations
    Hits         *SearchHits   `json:"hits"`         // the actual search hits
    Suggest      SearchSuggest `json:"suggest"`      // results from suggesters
    Aggregations Aggregations  `json:"aggregations"` // results from aggregations
    TimedOut     bool          `json:"timed_out"`    // true if the search timed out
}

type SearchService Uses

type SearchService struct {
    // contains filtered or unexported fields
}

func NewSearchService Uses

func NewSearchService(conn *connection.Connection) *SearchService

func (*SearchService) Body Uses

func (s *SearchService) Body(body string) *SearchService

func (*SearchService) Do Uses

func (s *SearchService) Do() (*SearchResponse, error)

func (*SearchService) Type Uses

func (s *SearchService) Type(_type string) *SearchService

func (*SearchService) Types Uses

func (s *SearchService) Types(_types []string) *SearchService

func (*SearchService) URLParams Uses

func (s *SearchService) URLParams(params url.Values) *SearchService

type SearchServiceOptions Uses

type SearchServiceOptions struct {
    Type   []string `validate:"required"`
    Body   string   `validate:"required"`
    Params url.Values
}

type SearchStreamResponse Uses

type SearchStreamResponse struct {
    // contains filtered or unexported fields
}

func (*SearchStreamResponse) Next Uses

func (s *SearchStreamResponse) Next() (getResponse *GetResponse, err error)

type SearchStreamService Uses

type SearchStreamService struct {
    SearchService
}

func NewSearchStreamService Uses

func NewSearchStreamService(conn *connection.Connection) *SearchStreamService

func (*SearchStreamService) Body Uses

func (s *SearchStreamService) Body(body string) *SearchStreamService

func (*SearchStreamService) Do Uses

func (s *SearchStreamService) Do() (*SearchStreamResponse, error)

func (*SearchStreamService) Type Uses

func (s *SearchStreamService) Type(_type string) *SearchStreamService

func (*SearchStreamService) Types Uses

func (s *SearchStreamService) Types(_types []string) *SearchStreamService

func (*SearchStreamService) URLParams Uses

func (s *SearchStreamService) URLParams(params url.Values) *SearchStreamService

type SearchStreamToURLOptions Uses

type SearchStreamToURLOptions struct {
    Type     []string         `json:"type" validate:"required"`
    Webhooks []interface{}    `json:"webhooks" validate:"required"`
    Query    *json.RawMessage `json:"query" validate:"required"`
    // contains filtered or unexported fields
}

type SearchStreamToURLResponse Uses

type SearchStreamToURLResponse struct {
    IndexResponse
    // contains filtered or unexported fields
}

func (*SearchStreamToURLResponse) Stop Uses

func (s *SearchStreamToURLResponse) Stop() (*DeleteResponse, error)

type SearchStreamToURLService Uses

type SearchStreamToURLService struct {
    // contains filtered or unexported fields
}

func NewSearchStreamToURLService Uses

func NewSearchStreamToURLService(conn *connection.Connection) *SearchStreamToURLService

func (*SearchStreamToURLService) AddWebhook Uses

func (s *SearchStreamToURLService) AddWebhook(webhook interface{}) *SearchStreamToURLService

func (*SearchStreamToURLService) Do Uses

func (s *SearchStreamToURLService) Do() (*SearchStreamToURLResponse, error)

func (*SearchStreamToURLService) Query Uses

func (s *SearchStreamToURLService) Query(query string) *SearchStreamToURLService

func (*SearchStreamToURLService) Type Uses

func (s *SearchStreamToURLService) Type(_type string) *SearchStreamToURLService

func (*SearchStreamToURLService) Types Uses

func (s *SearchStreamToURLService) Types(_types []string) *SearchStreamToURLService

type SearchSuggest Uses

type SearchSuggest map[string][]SearchSuggestion

Suggest SearchSuggest is a map of suggestions. See http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-suggesters.html.

type SearchSuggestion Uses

type SearchSuggestion struct {
    Text    string                   `json:"text"`
    Offset  int                      `json:"offset"`
    Length  int                      `json:"length"`
    Options []SearchSuggestionOption `json:"options"`
}

SearchSuggestion is a single search suggestion. See http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-suggesters.html.

type SearchSuggestionOption Uses

type SearchSuggestionOption struct {
    Text    string      `json:"text"`
    Score   float64     `json:"score"`
    Freq    int         `json:"freq"`
    Payload interface{} `json:"payload"`
}

SearchSuggestionOption is an option of a SearchSuggestion. See http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-suggesters.html.

type UpdateResponse Uses

type UpdateResponse struct {
    Update      string       `json:"_index"`
    Type        string       `json:"_type"`
    Id          string       `json:"_id"`
    Version     int          `json:"_version"`
    Created     bool         `json:"created"`
    GetResponse *GetResponse `json:"get"`
}

type UpdateService Uses

type UpdateService struct {
    // contains filtered or unexported fields
}

func NewUpdateService Uses

func NewUpdateService(conn *connection.Connection) *UpdateService

func (*UpdateService) Body Uses

func (u *UpdateService) Body(body string) *UpdateService

func (*UpdateService) Do Uses

func (u *UpdateService) Do() (*UpdateResponse, error)

func (*UpdateService) Id Uses

func (u *UpdateService) Id(_id string) *UpdateService

func (*UpdateService) Type Uses

func (u *UpdateService) Type(_type string) *UpdateService

func (*UpdateService) URLParams Uses

func (u *UpdateService) URLParams(params url.Values) *UpdateService

type UpdateServiceOptions Uses

type UpdateServiceOptions struct {
    Type   string `validate:"required"`
    Id     string `validate:"required"`
    Body   string `validate:"required"`
    Params url.Values
}

type Webhook Uses

type Webhook struct {
    URL      string `json:"url,omitempty" validate:"required"`
    Method   string `json:"method,omitempty" validate:"required"`
    Body     string `json:"body, omitempty"`
    Interval int    `json:"body,omitempty"`
    Count    int    `json:"body,omitempty"`
}

Package actions imports 9 packages (graph) and is imported by 1 packages. Updated 2016-07-15. Refresh now. Tools for package owners.