repo
stringlengths
5
67
path
stringlengths
4
218
func_name
stringlengths
0
151
original_string
stringlengths
52
373k
language
stringclasses
6 values
code
stringlengths
52
373k
code_tokens
listlengths
10
512
docstring
stringlengths
3
47.2k
docstring_tokens
listlengths
3
234
sha
stringlengths
40
40
url
stringlengths
85
339
partition
stringclasses
3 values
algolia/algoliasearch-client-go
algolia/internal/opt/exact_on_single_word_query.go
ExtractExactOnSingleWordQuery
func ExtractExactOnSingleWordQuery(opts ...interface{}) *opt.ExactOnSingleWordQueryOption { for _, o := range opts { if v, ok := o.(*opt.ExactOnSingleWordQueryOption); ok { return v } } return nil }
go
func ExtractExactOnSingleWordQuery(opts ...interface{}) *opt.ExactOnSingleWordQueryOption { for _, o := range opts { if v, ok := o.(*opt.ExactOnSingleWordQueryOption); ok { return v } } return nil }
[ "func", "ExtractExactOnSingleWordQuery", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "ExactOnSingleWordQueryOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".",...
// ExtractExactOnSingleWordQuery returns the first found ExactOnSingleWordQueryOption from the // given variadic arguments or nil otherwise.
[ "ExtractExactOnSingleWordQuery", "returns", "the", "first", "found", "ExactOnSingleWordQueryOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/exact_on_single_word_query.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/internal/opt/cluster_name.go
ExtractClusterName
func ExtractClusterName(opts ...interface{}) *opt.ClusterNameOption { for _, o := range opts { if v, ok := o.(*opt.ClusterNameOption); ok { return v } } return nil }
go
func ExtractClusterName(opts ...interface{}) *opt.ClusterNameOption { for _, o := range opts { if v, ok := o.(*opt.ClusterNameOption); ok { return v } } return nil }
[ "func", "ExtractClusterName", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "ClusterNameOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "ClusterNameOption"...
// ExtractClusterName returns the first found ClusterNameOption from the // given variadic arguments or nil otherwise.
[ "ExtractClusterName", "returns", "the", "first", "found", "ClusterNameOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/cluster_name.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/opt/primary.go
PrimaryEqual
func PrimaryEqual(o1, o2 *PrimaryOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func PrimaryEqual(o1, o2 *PrimaryOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "PrimaryEqual", "(", "o1", ",", "o2", "*", "PrimaryOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "Equal", "(", ...
// PrimaryEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "PrimaryEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", "defaul...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/primary.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/opt/allow_compression_of_integer_array.go
AllowCompressionOfIntegerArrayEqual
func AllowCompressionOfIntegerArrayEqual(o1, o2 *AllowCompressionOfIntegerArrayOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func AllowCompressionOfIntegerArrayEqual(o1, o2 *AllowCompressionOfIntegerArrayOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "AllowCompressionOfIntegerArrayEqual", "(", "o1", ",", "o2", "*", "AllowCompressionOfIntegerArrayOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", ...
// AllowCompressionOfIntegerArrayEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "AllowCompressionOfIntegerArrayEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/allow_compression_of_integer_array.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/opt/percentile_computation.go
PercentileComputationEqual
func PercentileComputationEqual(o1, o2 *PercentileComputationOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func PercentileComputationEqual(o1, o2 *PercentileComputationOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "PercentileComputationEqual", "(", "o1", ",", "o2", "*", "PercentileComputationOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2",...
// PercentileComputationEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "PercentileComputationEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "t...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/percentile_computation.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/opt/exact_on_single_word_query.go
ExactOnSingleWordQueryEqual
func ExactOnSingleWordQueryEqual(o1, o2 *ExactOnSingleWordQueryOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func ExactOnSingleWordQueryEqual(o1, o2 *ExactOnSingleWordQueryOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "ExactOnSingleWordQueryEqual", "(", "o1", ",", "o2", "*", "ExactOnSingleWordQueryOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2...
// ExactOnSingleWordQueryEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "ExactOnSingleWordQueryEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/exact_on_single_word_query.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/search/index_rules.go
GetRule
func (i *Index) GetRule(objectID string, opts ...interface{}) (rule Rule, err error) { if objectID == "" { err = errs.ErrMissingObjectID return } path := i.path("/rules/%s", url.QueryEscape(objectID)) err = i.transport.Request(&rule, http.MethodGet, path, nil, call.Read, opts...) return }
go
func (i *Index) GetRule(objectID string, opts ...interface{}) (rule Rule, err error) { if objectID == "" { err = errs.ErrMissingObjectID return } path := i.path("/rules/%s", url.QueryEscape(objectID)) err = i.transport.Request(&rule, http.MethodGet, path, nil, call.Read, opts...) return }
[ "func", "(", "i", "*", "Index", ")", "GetRule", "(", "objectID", "string", ",", "opts", "...", "interface", "{", "}", ")", "(", "rule", "Rule", ",", "err", "error", ")", "{", "if", "objectID", "==", "\"\"", "{", "err", "=", "errs", ".", "ErrMissing...
// GetRule retrieves the rule identified by the given objectID.
[ "GetRule", "retrieves", "the", "rule", "identified", "by", "the", "given", "objectID", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/index_rules.go#L14-L23
train
algolia/algoliasearch-client-go
algolia/search/index_rules.go
SaveRule
func (i *Index) SaveRule(rule Rule, opts ...interface{}) (res UpdateTaskRes, err error) { if rule.ObjectID == "" { err = errs.ErrMissingObjectID res.wait = noWait return } path := i.path("/rules/%s", url.QueryEscape(rule.ObjectID)) err = i.transport.Request(&res, http.MethodPut, path, rule, call.Write, opts...) res.wait = i.WaitTask return }
go
func (i *Index) SaveRule(rule Rule, opts ...interface{}) (res UpdateTaskRes, err error) { if rule.ObjectID == "" { err = errs.ErrMissingObjectID res.wait = noWait return } path := i.path("/rules/%s", url.QueryEscape(rule.ObjectID)) err = i.transport.Request(&res, http.MethodPut, path, rule, call.Write, opts...) res.wait = i.WaitTask return }
[ "func", "(", "i", "*", "Index", ")", "SaveRule", "(", "rule", "Rule", ",", "opts", "...", "interface", "{", "}", ")", "(", "res", "UpdateTaskRes", ",", "err", "error", ")", "{", "if", "rule", ".", "ObjectID", "==", "\"\"", "{", "err", "=", "errs", ...
// SaveRule saves the given rule.
[ "SaveRule", "saves", "the", "given", "rule", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/index_rules.go#L26-L37
train
algolia/algoliasearch-client-go
algolia/search/index_rules.go
SaveRules
func (i *Index) SaveRules(rules []Rule, opts ...interface{}) (res UpdateTaskRes, err error) { if clearExistingRules := iopt.ExtractClearExistingRules(opts...); clearExistingRules != nil { opts = opt.InsertExtraURLParam(opts, "clearExistingRules", clearExistingRules.Get()) } path := i.path("/rules/batch") err = i.transport.Request(&res, http.MethodPost, path, rules, call.Write, opts...) res.wait = i.WaitTask return }
go
func (i *Index) SaveRules(rules []Rule, opts ...interface{}) (res UpdateTaskRes, err error) { if clearExistingRules := iopt.ExtractClearExistingRules(opts...); clearExistingRules != nil { opts = opt.InsertExtraURLParam(opts, "clearExistingRules", clearExistingRules.Get()) } path := i.path("/rules/batch") err = i.transport.Request(&res, http.MethodPost, path, rules, call.Write, opts...) res.wait = i.WaitTask return }
[ "func", "(", "i", "*", "Index", ")", "SaveRules", "(", "rules", "[", "]", "Rule", ",", "opts", "...", "interface", "{", "}", ")", "(", "res", "UpdateTaskRes", ",", "err", "error", ")", "{", "if", "clearExistingRules", ":=", "iopt", ".", "ExtractClearEx...
// SaveRule saves the given rules. // // Unlike SaveObjects, this method does not batch the given rules i.e. all rules // are sent in a single call.
[ "SaveRule", "saves", "the", "given", "rules", ".", "Unlike", "SaveObjects", "this", "method", "does", "not", "batch", "the", "given", "rules", "i", ".", "e", ".", "all", "rules", "are", "sent", "in", "a", "single", "call", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/index_rules.go#L43-L51
train
algolia/algoliasearch-client-go
algolia/search/index_rules.go
DeleteRule
func (i *Index) DeleteRule(objectID string, opts ...interface{}) (res UpdateTaskRes, err error) { if objectID == "" { err = errs.ErrMissingObjectID res.wait = noWait return } path := i.path("/rules/%s", url.QueryEscape(objectID)) err = i.transport.Request(&res, http.MethodDelete, path, nil, call.Write, opts...) res.wait = i.WaitTask return }
go
func (i *Index) DeleteRule(objectID string, opts ...interface{}) (res UpdateTaskRes, err error) { if objectID == "" { err = errs.ErrMissingObjectID res.wait = noWait return } path := i.path("/rules/%s", url.QueryEscape(objectID)) err = i.transport.Request(&res, http.MethodDelete, path, nil, call.Write, opts...) res.wait = i.WaitTask return }
[ "func", "(", "i", "*", "Index", ")", "DeleteRule", "(", "objectID", "string", ",", "opts", "...", "interface", "{", "}", ")", "(", "res", "UpdateTaskRes", ",", "err", "error", ")", "{", "if", "objectID", "==", "\"\"", "{", "err", "=", "errs", ".", ...
// DeleteRule removes the rule identified by the given objectID.
[ "DeleteRule", "removes", "the", "rule", "identified", "by", "the", "given", "objectID", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/index_rules.go#L62-L73
train
algolia/algoliasearch-client-go
algolia/search/index_rules.go
ReplaceAllRules
func (i *Index) ReplaceAllRules(rules []Rule, opts ...interface{}) (UpdateTaskRes, error) { opts = opt.InsertOrReplaceOption(opts, opt.ClearExistingRules(true)) return i.SaveRules(rules, opts...) }
go
func (i *Index) ReplaceAllRules(rules []Rule, opts ...interface{}) (UpdateTaskRes, error) { opts = opt.InsertOrReplaceOption(opts, opt.ClearExistingRules(true)) return i.SaveRules(rules, opts...) }
[ "func", "(", "i", "*", "Index", ")", "ReplaceAllRules", "(", "rules", "[", "]", "Rule", ",", "opts", "...", "interface", "{", "}", ")", "(", "UpdateTaskRes", ",", "error", ")", "{", "opts", "=", "opt", ".", "InsertOrReplaceOption", "(", "opts", ",", ...
// ReplaceAllRules replaces any existing rules with the given ones.
[ "ReplaceAllRules", "replaces", "any", "existing", "rules", "with", "the", "given", "ones", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/index_rules.go#L86-L89
train
algolia/algoliasearch-client-go
algolia/search/index_rules.go
BrowseRules
func (i *Index) BrowseRules(opts ...interface{}) (*RuleIterator, error) { browser := func(page int) (SearchRulesRes, error) { opts = opt.InsertOrReplaceOption(opts, opt.Page(page)) return i.SearchRules("", opts...) } return newRuleIterator(browser) }
go
func (i *Index) BrowseRules(opts ...interface{}) (*RuleIterator, error) { browser := func(page int) (SearchRulesRes, error) { opts = opt.InsertOrReplaceOption(opts, opt.Page(page)) return i.SearchRules("", opts...) } return newRuleIterator(browser) }
[ "func", "(", "i", "*", "Index", ")", "BrowseRules", "(", "opts", "...", "interface", "{", "}", ")", "(", "*", "RuleIterator", ",", "error", ")", "{", "browser", ":=", "func", "(", "page", "int", ")", "(", "SearchRulesRes", ",", "error", ")", "{", "...
// BrowseRules returns an iterator which will retrieve rules one by one from the // index.
[ "BrowseRules", "returns", "an", "iterator", "which", "will", "retrieve", "rules", "one", "by", "one", "from", "the", "index", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/index_rules.go#L93-L99
train
algolia/algoliasearch-client-go
algolia/internal/opt/type.go
ExtractType
func ExtractType(opts ...interface{}) *opt.TypeOption { for _, o := range opts { if v, ok := o.(*opt.TypeOption); ok { return v } } return nil }
go
func ExtractType(opts ...interface{}) *opt.TypeOption { for _, o := range opts { if v, ok := o.(*opt.TypeOption); ok { return v } } return nil }
[ "func", "ExtractType", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "TypeOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "TypeOption", ")", ";", "ok...
// ExtractType returns the first found TypeOption from the // given variadic arguments or nil otherwise.
[ "ExtractType", "returns", "the", "first", "found", "TypeOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/type.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/internal/opt/distinct.go
ExtractDistinct
func ExtractDistinct(opts ...interface{}) *opt.DistinctOption { for _, o := range opts { if v, ok := o.(*opt.DistinctOption); ok { return v } } return nil }
go
func ExtractDistinct(opts ...interface{}) *opt.DistinctOption { for _, o := range opts { if v, ok := o.(*opt.DistinctOption); ok { return v } } return nil }
[ "func", "ExtractDistinct", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "DistinctOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "DistinctOption", ")", ...
// ExtractDistinct returns the first found DistinctOption from the // given variadic arguments or nil otherwise.
[ "ExtractDistinct", "returns", "the", "first", "found", "DistinctOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/distinct.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/search/rule.go
Equal
func (r Rule) Equal(r2 Rule) bool { if !(r.ObjectID == r2.ObjectID && r.Description == r2.Description && r.Enabled == r2.Enabled && len(r.Validity) == len(r2.Validity) && reflect.DeepEqual(r.Condition, r2.Condition) && reflect.DeepEqual(r.Consequence, r2.Consequence)) { return false } for i, r := range r.Validity { if !r.Equal(r2.Validity[i]) { return false } } return true }
go
func (r Rule) Equal(r2 Rule) bool { if !(r.ObjectID == r2.ObjectID && r.Description == r2.Description && r.Enabled == r2.Enabled && len(r.Validity) == len(r2.Validity) && reflect.DeepEqual(r.Condition, r2.Condition) && reflect.DeepEqual(r.Consequence, r2.Consequence)) { return false } for i, r := range r.Validity { if !r.Equal(r2.Validity[i]) { return false } } return true }
[ "func", "(", "r", "Rule", ")", "Equal", "(", "r2", "Rule", ")", "bool", "{", "if", "!", "(", "r", ".", "ObjectID", "==", "r2", ".", "ObjectID", "&&", "r", ".", "Description", "==", "r2", ".", "Description", "&&", "r", ".", "Enabled", "==", "r2", ...
// Equal returns true if the Rules are equal. It returns false otherwise.
[ "Equal", "returns", "true", "if", "the", "Rules", "are", "equal", ".", "It", "returns", "false", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/rule.go#L48-L65
train
algolia/algoliasearch-client-go
algolia/search/rule.go
Equal
func (r TimeRange) Equal(r2 TimeRange) bool { return r.From.Equal(r2.From) && r.Until.Equal(r2.Until) }
go
func (r TimeRange) Equal(r2 TimeRange) bool { return r.From.Equal(r2.From) && r.Until.Equal(r2.Until) }
[ "func", "(", "r", "TimeRange", ")", "Equal", "(", "r2", "TimeRange", ")", "bool", "{", "return", "r", ".", "From", ".", "Equal", "(", "r2", ".", "From", ")", "&&", "r", ".", "Until", ".", "Equal", "(", "r2", ".", "Until", ")", "\n", "}" ]
// Equal returns true if the TimeRanges are equal. It returns false otherwise.
[ "Equal", "returns", "true", "if", "the", "TimeRanges", "are", "equal", ".", "It", "returns", "false", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/rule.go#L68-L70
train
algolia/algoliasearch-client-go
algolia/opt/disable_exact_on_attributes.go
DisableExactOnAttributesEqual
func DisableExactOnAttributesEqual(o1, o2 *DisableExactOnAttributesOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func DisableExactOnAttributesEqual(o1, o2 *DisableExactOnAttributesOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "DisableExactOnAttributesEqual", "(", "o1", ",", "o2", "*", "DisableExactOnAttributesOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", ...
// DisableExactOnAttributesEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "DisableExactOnAttributesEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", ...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/disable_exact_on_attributes.go#L58-L66
train
algolia/algoliasearch-client-go
algolia/opt/optional_filters.go
OptionalFiltersEqual
func OptionalFiltersEqual(o1, o2 *OptionalFiltersOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func OptionalFiltersEqual(o1, o2 *OptionalFiltersOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "OptionalFiltersEqual", "(", "o1", ",", "o2", "*", "OptionalFiltersOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "E...
// OptionalFiltersEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "OptionalFiltersEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", ...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/optional_filters.go#L66-L74
train
algolia/algoliasearch-client-go
algolia/opt/forward_to_replicas.go
ForwardToReplicasEqual
func ForwardToReplicasEqual(o1, o2 *ForwardToReplicasOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func ForwardToReplicasEqual(o1, o2 *ForwardToReplicasOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "ForwardToReplicasEqual", "(", "o1", ",", "o2", "*", "ForwardToReplicasOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", ...
// ForwardToReplicasEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "ForwardToReplicasEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the",...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/forward_to_replicas.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/opt/limit.go
LimitEqual
func LimitEqual(o1, o2 *LimitOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func LimitEqual(o1, o2 *LimitOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "LimitEqual", "(", "o1", ",", "o2", "*", "LimitOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "Equal", "(", "o1"...
// LimitEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "LimitEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", "default"...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/limit.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/opt/typo_tolerance.go
UnmarshalJSON
func (o *TypoToleranceOption) UnmarshalJSON(data []byte) error { if string(data) == "null" { o.value = typoToleranceTrue return nil } var v string if err := json.Unmarshal(data, &v); err == nil { o.value = v return nil } var b bool if err := json.Unmarshal(data, &b); err == nil { o.value = fmt.Sprintf("%t", b) return nil } return errs.ErrJSONDecode(data, "TypoTolerance") }
go
func (o *TypoToleranceOption) UnmarshalJSON(data []byte) error { if string(data) == "null" { o.value = typoToleranceTrue return nil } var v string if err := json.Unmarshal(data, &v); err == nil { o.value = v return nil } var b bool if err := json.Unmarshal(data, &b); err == nil { o.value = fmt.Sprintf("%t", b) return nil } return errs.ErrJSONDecode(data, "TypoTolerance") }
[ "func", "(", "o", "*", "TypoToleranceOption", ")", "UnmarshalJSON", "(", "data", "[", "]", "byte", ")", "error", "{", "if", "string", "(", "data", ")", "==", "\"null\"", "{", "o", ".", "value", "=", "typoToleranceTrue", "\n", "return", "nil", "\n", "}"...
// UnmarshalJSON implements the json.Unmarshaler interface for // TypoToleranceOption.
[ "UnmarshalJSON", "implements", "the", "json", ".", "Unmarshaler", "interface", "for", "TypoToleranceOption", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/typo_tolerance.go#L62-L81
train
algolia/algoliasearch-client-go
algolia/opt/typo_tolerance.go
TypoToleranceEqual
func TypoToleranceEqual(o1, o2 *TypoToleranceOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func TypoToleranceEqual(o1, o2 *TypoToleranceOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "TypoToleranceEqual", "(", "o1", ",", "o2", "*", "TypoToleranceOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "Equal...
// TypoToleranceEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "TypoToleranceEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", "...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/typo_tolerance.go#L96-L104
train
algolia/algoliasearch-client-go
algolia/internal/opt/disable_exact_on_attributes.go
ExtractDisableExactOnAttributes
func ExtractDisableExactOnAttributes(opts ...interface{}) *opt.DisableExactOnAttributesOption { for _, o := range opts { if v, ok := o.(*opt.DisableExactOnAttributesOption); ok { return v } } return nil }
go
func ExtractDisableExactOnAttributes(opts ...interface{}) *opt.DisableExactOnAttributesOption { for _, o := range opts { if v, ok := o.(*opt.DisableExactOnAttributesOption); ok { return v } } return nil }
[ "func", "ExtractDisableExactOnAttributes", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "DisableExactOnAttributesOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ...
// ExtractDisableExactOnAttributes returns the first found DisableExactOnAttributesOption from the // given variadic arguments or nil otherwise.
[ "ExtractDisableExactOnAttributes", "returns", "the", "first", "found", "DisableExactOnAttributesOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/disable_exact_on_attributes.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/internal/opt/auto_generate_object_id_if_not_exist.go
ExtractAutoGenerateObjectIDIfNotExist
func ExtractAutoGenerateObjectIDIfNotExist(opts ...interface{}) *opt.AutoGenerateObjectIDIfNotExistOption { for _, o := range opts { if v, ok := o.(*opt.AutoGenerateObjectIDIfNotExistOption); ok { return v } } return nil }
go
func ExtractAutoGenerateObjectIDIfNotExist(opts ...interface{}) *opt.AutoGenerateObjectIDIfNotExistOption { for _, o := range opts { if v, ok := o.(*opt.AutoGenerateObjectIDIfNotExistOption); ok { return v } } return nil }
[ "func", "ExtractAutoGenerateObjectIDIfNotExist", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "AutoGenerateObjectIDIfNotExistOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*",...
// ExtractAutoGenerateObjectIDIfNotExist returns the first found AutoGenerateObjectIDIfNotExistOption from the // given variadic arguments or nil otherwise.
[ "ExtractAutoGenerateObjectIDIfNotExist", "returns", "the", "first", "found", "AutoGenerateObjectIDIfNotExistOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/auto_generate_object_id_if_not_exist.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/internal/opt/inside_bounding_box.go
ExtractInsideBoundingBox
func ExtractInsideBoundingBox(opts ...interface{}) *opt.InsideBoundingBoxOption { for _, o := range opts { if v, ok := o.(*opt.InsideBoundingBoxOption); ok { return v } } return nil }
go
func ExtractInsideBoundingBox(opts ...interface{}) *opt.InsideBoundingBoxOption { for _, o := range opts { if v, ok := o.(*opt.InsideBoundingBoxOption); ok { return v } } return nil }
[ "func", "ExtractInsideBoundingBox", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "InsideBoundingBoxOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "Inside...
// ExtractInsideBoundingBox returns the first found InsideBoundingBoxOption from the // given variadic arguments or nil otherwise.
[ "ExtractInsideBoundingBox", "returns", "the", "first", "found", "InsideBoundingBoxOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/inside_bounding_box.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/internal/opt/around_lat_lng_via_ip.go
ExtractAroundLatLngViaIP
func ExtractAroundLatLngViaIP(opts ...interface{}) *opt.AroundLatLngViaIPOption { for _, o := range opts { if v, ok := o.(*opt.AroundLatLngViaIPOption); ok { return v } } return nil }
go
func ExtractAroundLatLngViaIP(opts ...interface{}) *opt.AroundLatLngViaIPOption { for _, o := range opts { if v, ok := o.(*opt.AroundLatLngViaIPOption); ok { return v } } return nil }
[ "func", "ExtractAroundLatLngViaIP", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "AroundLatLngViaIPOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "Around...
// ExtractAroundLatLngViaIP returns the first found AroundLatLngViaIPOption from the // given variadic arguments or nil otherwise.
[ "ExtractAroundLatLngViaIP", "returns", "the", "first", "found", "AroundLatLngViaIPOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/around_lat_lng_via_ip.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/opt/snippet_ellipsis_text.go
UnmarshalJSON
func (o *SnippetEllipsisTextOption) UnmarshalJSON(data []byte) error { if string(data) == "null" { o.value = newDefaultSnippetEllipsisTextValue return nil } return json.Unmarshal(data, &o.value) }
go
func (o *SnippetEllipsisTextOption) UnmarshalJSON(data []byte) error { if string(data) == "null" { o.value = newDefaultSnippetEllipsisTextValue return nil } return json.Unmarshal(data, &o.value) }
[ "func", "(", "o", "*", "SnippetEllipsisTextOption", ")", "UnmarshalJSON", "(", "data", "[", "]", "byte", ")", "error", "{", "if", "string", "(", "data", ")", "==", "\"null\"", "{", "o", ".", "value", "=", "newDefaultSnippetEllipsisTextValue", "\n", "return",...
// UnmarshalJSON implements the json.Unmarshaler interface for // SnippetEllipsisTextOption.
[ "UnmarshalJSON", "implements", "the", "json", ".", "Unmarshaler", "interface", "for", "SnippetEllipsisTextOption", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/snippet_ellipsis_text.go#L37-L43
train
algolia/algoliasearch-client-go
algolia/opt/snippet_ellipsis_text.go
SnippetEllipsisTextEqual
func SnippetEllipsisTextEqual(o1, o2 *SnippetEllipsisTextOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func SnippetEllipsisTextEqual(o1, o2 *SnippetEllipsisTextOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "SnippetEllipsisTextEqual", "(", "o1", ",", "o2", "*", "SnippetEllipsisTextOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", "...
// SnippetEllipsisTextEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "SnippetEllipsisTextEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/snippet_ellipsis_text.go#L64-L72
train
algolia/algoliasearch-client-go
algolia/internal/opt/around_precision.go
ExtractAroundPrecision
func ExtractAroundPrecision(opts ...interface{}) *opt.AroundPrecisionOption { for _, o := range opts { if v, ok := o.(*opt.AroundPrecisionOption); ok { return v } } return nil }
go
func ExtractAroundPrecision(opts ...interface{}) *opt.AroundPrecisionOption { for _, o := range opts { if v, ok := o.(*opt.AroundPrecisionOption); ok { return v } } return nil }
[ "func", "ExtractAroundPrecision", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "AroundPrecisionOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "AroundPrec...
// ExtractAroundPrecision returns the first found AroundPrecisionOption from the // given variadic arguments or nil otherwise.
[ "ExtractAroundPrecision", "returns", "the", "first", "found", "AroundPrecisionOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/around_precision.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/opt/searchable_attributes.go
SearchableAttributesEqual
func SearchableAttributesEqual(o1, o2 *SearchableAttributesOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func SearchableAttributesEqual(o1, o2 *SearchableAttributesOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "SearchableAttributesEqual", "(", "o1", ",", "o2", "*", "SearchableAttributesOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ...
// SearchableAttributesEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "SearchableAttributesEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "th...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/searchable_attributes.go#L58-L66
train
algolia/algoliasearch-client-go
algolia/internal/opt/min_proximity.go
ExtractMinProximity
func ExtractMinProximity(opts ...interface{}) *opt.MinProximityOption { for _, o := range opts { if v, ok := o.(*opt.MinProximityOption); ok { return v } } return nil }
go
func ExtractMinProximity(opts ...interface{}) *opt.MinProximityOption { for _, o := range opts { if v, ok := o.(*opt.MinProximityOption); ok { return v } } return nil }
[ "func", "ExtractMinProximity", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "MinProximityOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "MinProximityOpti...
// ExtractMinProximity returns the first found MinProximityOption from the // given variadic arguments or nil otherwise.
[ "ExtractMinProximity", "returns", "the", "first", "found", "MinProximityOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/min_proximity.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/internal/opt/ignore_plurals.go
ExtractIgnorePlurals
func ExtractIgnorePlurals(opts ...interface{}) *opt.IgnorePluralsOption { for _, o := range opts { if v, ok := o.(*opt.IgnorePluralsOption); ok { return v } } return nil }
go
func ExtractIgnorePlurals(opts ...interface{}) *opt.IgnorePluralsOption { for _, o := range opts { if v, ok := o.(*opt.IgnorePluralsOption); ok { return v } } return nil }
[ "func", "ExtractIgnorePlurals", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "IgnorePluralsOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "IgnorePluralsO...
// ExtractIgnorePlurals returns the first found IgnorePluralsOption from the // given variadic arguments or nil otherwise.
[ "ExtractIgnorePlurals", "returns", "the", "first", "found", "IgnorePluralsOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/ignore_plurals.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/opt/restrict_sources.go
RestrictSourcesEqual
func RestrictSourcesEqual(o1, o2 *RestrictSourcesOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func RestrictSourcesEqual(o1, o2 *RestrictSourcesOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "RestrictSourcesEqual", "(", "o1", ",", "o2", "*", "RestrictSourcesOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "E...
// RestrictSourcesEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "RestrictSourcesEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", ...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/restrict_sources.go#L58-L66
train
algolia/algoliasearch-client-go
algolia/internal/opt/inside_polygon.go
ExtractInsidePolygon
func ExtractInsidePolygon(opts ...interface{}) *opt.InsidePolygonOption { for _, o := range opts { if v, ok := o.(*opt.InsidePolygonOption); ok { return v } } return nil }
go
func ExtractInsidePolygon(opts ...interface{}) *opt.InsidePolygonOption { for _, o := range opts { if v, ok := o.(*opt.InsidePolygonOption); ok { return v } } return nil }
[ "func", "ExtractInsidePolygon", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "InsidePolygonOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "InsidePolygonO...
// ExtractInsidePolygon returns the first found InsidePolygonOption from the // given variadic arguments or nil otherwise.
[ "ExtractInsidePolygon", "returns", "the", "first", "found", "InsidePolygonOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/inside_polygon.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/opt/restrict_indices.go
RestrictIndicesEqual
func RestrictIndicesEqual(o1, o2 *RestrictIndicesOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func RestrictIndicesEqual(o1, o2 *RestrictIndicesOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "RestrictIndicesEqual", "(", "o1", ",", "o2", "*", "RestrictIndicesOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "E...
// RestrictIndicesEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "RestrictIndicesEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", ...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/restrict_indices.go#L58-L66
train
algolia/algoliasearch-client-go
algolia/internal/opt/disable_typo_tolerance_on_words.go
ExtractDisableTypoToleranceOnWords
func ExtractDisableTypoToleranceOnWords(opts ...interface{}) *opt.DisableTypoToleranceOnWordsOption { for _, o := range opts { if v, ok := o.(*opt.DisableTypoToleranceOnWordsOption); ok { return v } } return nil }
go
func ExtractDisableTypoToleranceOnWords(opts ...interface{}) *opt.DisableTypoToleranceOnWordsOption { for _, o := range opts { if v, ok := o.(*opt.DisableTypoToleranceOnWordsOption); ok { return v } } return nil }
[ "func", "ExtractDisableTypoToleranceOnWords", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "DisableTypoToleranceOnWordsOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "op...
// ExtractDisableTypoToleranceOnWords returns the first found DisableTypoToleranceOnWordsOption from the // given variadic arguments or nil otherwise.
[ "ExtractDisableTypoToleranceOnWords", "returns", "the", "first", "found", "DisableTypoToleranceOnWordsOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/disable_typo_tolerance_on_words.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/opt/advanced_syntax_features.go
AdvancedSyntaxFeaturesEqual
func AdvancedSyntaxFeaturesEqual(o1, o2 *AdvancedSyntaxFeaturesOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func AdvancedSyntaxFeaturesEqual(o1, o2 *AdvancedSyntaxFeaturesOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "AdvancedSyntaxFeaturesEqual", "(", "o1", ",", "o2", "*", "AdvancedSyntaxFeaturesOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2...
// AdvancedSyntaxFeaturesEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "AdvancedSyntaxFeaturesEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/advanced_syntax_features.go#L58-L66
train
algolia/algoliasearch-client-go
algolia/internal/opt/ranking.go
ExtractRanking
func ExtractRanking(opts ...interface{}) *opt.RankingOption { for _, o := range opts { if v, ok := o.(*opt.RankingOption); ok { return v } } return nil }
go
func ExtractRanking(opts ...interface{}) *opt.RankingOption { for _, o := range opts { if v, ok := o.(*opt.RankingOption); ok { return v } } return nil }
[ "func", "ExtractRanking", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "RankingOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "RankingOption", ")", "...
// ExtractRanking returns the first found RankingOption from the // given variadic arguments or nil otherwise.
[ "ExtractRanking", "returns", "the", "first", "found", "RankingOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/ranking.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/internal/opt/index_name.go
ExtractIndexName
func ExtractIndexName(opts ...interface{}) *opt.IndexNameOption { for _, o := range opts { if v, ok := o.(*opt.IndexNameOption); ok { return v } } return nil }
go
func ExtractIndexName(opts ...interface{}) *opt.IndexNameOption { for _, o := range opts { if v, ok := o.(*opt.IndexNameOption); ok { return v } } return nil }
[ "func", "ExtractIndexName", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "IndexNameOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "IndexNameOption", ")...
// ExtractIndexName returns the first found IndexNameOption from the // given variadic arguments or nil otherwise.
[ "ExtractIndexName", "returns", "the", "first", "found", "IndexNameOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/index_name.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/opt/scopes.go
ScopesEqual
func ScopesEqual(o1, o2 *ScopesOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func ScopesEqual(o1, o2 *ScopesOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "ScopesEqual", "(", "o1", ",", "o2", "*", "ScopesOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "Equal", "(", "o...
// ScopesEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "ScopesEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", "default...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/scopes.go#L58-L66
train
algolia/algoliasearch-client-go
algolia/opt/around_precision.go
AroundPrecisionEqual
func AroundPrecisionEqual(o1, o2 *AroundPrecisionOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func AroundPrecisionEqual(o1, o2 *AroundPrecisionOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "AroundPrecisionEqual", "(", "o1", ",", "o2", "*", "AroundPrecisionOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "E...
// AroundPrecisionEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "AroundPrecisionEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", ...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/around_precision.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/internal/opt/user_token.go
ExtractUserToken
func ExtractUserToken(opts ...interface{}) *opt.UserTokenOption { for _, o := range opts { if v, ok := o.(*opt.UserTokenOption); ok { return v } } return nil }
go
func ExtractUserToken(opts ...interface{}) *opt.UserTokenOption { for _, o := range opts { if v, ok := o.(*opt.UserTokenOption); ok { return v } } return nil }
[ "func", "ExtractUserToken", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "UserTokenOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "UserTokenOption", ")...
// ExtractUserToken returns the first found UserTokenOption from the // given variadic arguments or nil otherwise.
[ "ExtractUserToken", "returns", "the", "first", "found", "UserTokenOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/user_token.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/internal/opt/advanced_syntax_features.go
ExtractAdvancedSyntaxFeatures
func ExtractAdvancedSyntaxFeatures(opts ...interface{}) *opt.AdvancedSyntaxFeaturesOption { for _, o := range opts { if v, ok := o.(*opt.AdvancedSyntaxFeaturesOption); ok { return v } } return nil }
go
func ExtractAdvancedSyntaxFeatures(opts ...interface{}) *opt.AdvancedSyntaxFeaturesOption { for _, o := range opts { if v, ok := o.(*opt.AdvancedSyntaxFeaturesOption); ok { return v } } return nil }
[ "func", "ExtractAdvancedSyntaxFeatures", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "AdvancedSyntaxFeaturesOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".",...
// ExtractAdvancedSyntaxFeatures returns the first found AdvancedSyntaxFeaturesOption from the // given variadic arguments or nil otherwise.
[ "ExtractAdvancedSyntaxFeatures", "returns", "the", "first", "found", "AdvancedSyntaxFeaturesOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/advanced_syntax_features.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/internal/opt/referers.go
ExtractReferers
func ExtractReferers(opts ...interface{}) *opt.ReferersOption { for _, o := range opts { if v, ok := o.(*opt.ReferersOption); ok { return v } } return nil }
go
func ExtractReferers(opts ...interface{}) *opt.ReferersOption { for _, o := range opts { if v, ok := o.(*opt.ReferersOption); ok { return v } } return nil }
[ "func", "ExtractReferers", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "ReferersOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "ReferersOption", ")", ...
// ExtractReferers returns the first found ReferersOption from the // given variadic arguments or nil otherwise.
[ "ExtractReferers", "returns", "the", "first", "found", "ReferersOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/referers.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/opt/extra_url_params.go
ExtraURLParamsEqual
func ExtraURLParamsEqual(o1, o2 *ExtraURLParamsOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func ExtraURLParamsEqual(o1, o2 *ExtraURLParamsOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "ExtraURLParamsEqual", "(", "o1", ",", "o2", "*", "ExtraURLParamsOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "Equ...
// ExtraURLParamsEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "ExtraURLParamsEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", ...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/extra_url_params.go#L58-L66
train
algolia/algoliasearch-client-go
algolia/opt/disable_prefix_on_attributes.go
UnmarshalJSON
func (o *DisablePrefixOnAttributesOption) UnmarshalJSON(data []byte) error { if string(data) == "null" { o.value = []string{} return nil } return json.Unmarshal(data, &o.value) }
go
func (o *DisablePrefixOnAttributesOption) UnmarshalJSON(data []byte) error { if string(data) == "null" { o.value = []string{} return nil } return json.Unmarshal(data, &o.value) }
[ "func", "(", "o", "*", "DisablePrefixOnAttributesOption", ")", "UnmarshalJSON", "(", "data", "[", "]", "byte", ")", "error", "{", "if", "string", "(", "data", ")", "==", "\"null\"", "{", "o", ".", "value", "=", "[", "]", "string", "{", "}", "\n", "re...
// UnmarshalJSON implements the json.Unmarshaler interface for // DisablePrefixOnAttributesOption.
[ "UnmarshalJSON", "implements", "the", "json", ".", "Unmarshaler", "interface", "for", "DisablePrefixOnAttributesOption", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/disable_prefix_on_attributes.go#L37-L43
train
algolia/algoliasearch-client-go
algolia/opt/disable_prefix_on_attributes.go
DisablePrefixOnAttributesEqual
func DisablePrefixOnAttributesEqual(o1, o2 *DisablePrefixOnAttributesOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func DisablePrefixOnAttributesEqual(o1, o2 *DisablePrefixOnAttributesOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "DisablePrefixOnAttributesEqual", "(", "o1", ",", "o2", "*", "DisablePrefixOnAttributesOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return",...
// DisablePrefixOnAttributesEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "DisablePrefixOnAttributesEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", ...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/disable_prefix_on_attributes.go#L58-L66
train
algolia/algoliasearch-client-go
algolia/opt/tag_filters.go
UnmarshalJSON
func (o *TagFiltersOption) UnmarshalJSON(data []byte) error { return json.Unmarshal(data, &o.comp) }
go
func (o *TagFiltersOption) UnmarshalJSON(data []byte) error { return json.Unmarshal(data, &o.comp) }
[ "func", "(", "o", "*", "TagFiltersOption", ")", "UnmarshalJSON", "(", "data", "[", "]", "byte", ")", "error", "{", "return", "json", ".", "Unmarshal", "(", "data", ",", "&", "o", ".", "comp", ")", "\n", "}" ]
// UnmarshalJSON implements the json.Unmarshaler interface for TagFiltersOption.
[ "UnmarshalJSON", "implements", "the", "json", ".", "Unmarshaler", "interface", "for", "TagFiltersOption", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/tag_filters.go#L52-L54
train
algolia/algoliasearch-client-go
algolia/opt/tag_filters.go
TagFiltersEqual
func TagFiltersEqual(o1, o2 *TagFiltersOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func TagFiltersEqual(o1, o2 *TagFiltersOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "TagFiltersEqual", "(", "o1", ",", "o2", "*", "TagFiltersOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "Equal", "...
// TagFiltersEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "TagFiltersEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", "def...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/tag_filters.go#L66-L74
train
algolia/algoliasearch-client-go
algolia/search/client_mcm.go
ListClusters
func (c *Client) ListClusters(opts ...interface{}) (res ListClustersRes, err error) { err = c.transport.Request(&res, http.MethodGet, "/1/clusters", nil, call.Read, opts...) return }
go
func (c *Client) ListClusters(opts ...interface{}) (res ListClustersRes, err error) { err = c.transport.Request(&res, http.MethodGet, "/1/clusters", nil, call.Read, opts...) return }
[ "func", "(", "c", "*", "Client", ")", "ListClusters", "(", "opts", "...", "interface", "{", "}", ")", "(", "res", "ListClustersRes", ",", "err", "error", ")", "{", "err", "=", "c", ".", "transport", ".", "Request", "(", "&", "res", ",", "http", "."...
// ListClusters list all the clusters managed by MCM.
[ "ListClusters", "list", "all", "the", "clusters", "managed", "by", "MCM", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/client_mcm.go#L13-L16
train
algolia/algoliasearch-client-go
algolia/search/client_mcm.go
ListUserIDs
func (c *Client) ListUserIDs(opts ...interface{}) (res ListUserIDsRes, err error) { opts = opt.InsertExtraURLParam(opts, "page", iopt.ExtractPage(opts...).Get()) opts = opt.InsertExtraURLParam(opts, "hitsPerPage", iopt.ExtractHitsPerPage(opts...).Get()) err = c.transport.Request(&res, http.MethodGet, "/1/clusters/mapping", nil, call.Read, opts...) return }
go
func (c *Client) ListUserIDs(opts ...interface{}) (res ListUserIDsRes, err error) { opts = opt.InsertExtraURLParam(opts, "page", iopt.ExtractPage(opts...).Get()) opts = opt.InsertExtraURLParam(opts, "hitsPerPage", iopt.ExtractHitsPerPage(opts...).Get()) err = c.transport.Request(&res, http.MethodGet, "/1/clusters/mapping", nil, call.Read, opts...) return }
[ "func", "(", "c", "*", "Client", ")", "ListUserIDs", "(", "opts", "...", "interface", "{", "}", ")", "(", "res", "ListUserIDsRes", ",", "err", "error", ")", "{", "opts", "=", "opt", ".", "InsertExtraURLParam", "(", "opts", ",", "\"page\"", ",", "iopt",...
// ListUserIDs list all the userIDs managed by MCM. // // Pagination can be implemented using the opt.Page and opt.HitsPerPage option // parameters.
[ "ListUserIDs", "list", "all", "the", "userIDs", "managed", "by", "MCM", ".", "Pagination", "can", "be", "implemented", "using", "the", "opt", ".", "Page", "and", "opt", ".", "HitsPerPage", "option", "parameters", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/client_mcm.go#L22-L27
train
algolia/algoliasearch-client-go
algolia/search/client_mcm.go
GetUserID
func (c *Client) GetUserID(userID string, opts ...interface{}) (res UserID, err error) { path := fmt.Sprintf("/1/clusters/mapping/%s", userID) err = c.transport.Request(&res, http.MethodGet, path, nil, call.Read, opts...) return }
go
func (c *Client) GetUserID(userID string, opts ...interface{}) (res UserID, err error) { path := fmt.Sprintf("/1/clusters/mapping/%s", userID) err = c.transport.Request(&res, http.MethodGet, path, nil, call.Read, opts...) return }
[ "func", "(", "c", "*", "Client", ")", "GetUserID", "(", "userID", "string", ",", "opts", "...", "interface", "{", "}", ")", "(", "res", "UserID", ",", "err", "error", ")", "{", "path", ":=", "fmt", ".", "Sprintf", "(", "\"/1/clusters/mapping/%s\"", ","...
// GetUserID retrieves the user, managed by MCM, according to the given userID.
[ "GetUserID", "retrieves", "the", "user", "managed", "by", "MCM", "according", "to", "the", "given", "userID", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/client_mcm.go#L30-L34
train
algolia/algoliasearch-client-go
algolia/search/client_mcm.go
AssignUserID
func (c *Client) AssignUserID(userID, clusterName string, opts ...interface{}) (res AssignUserIDRes, err error) { opts = opt.InsertExtraHeader(opts, "X-Algolia-User-ID", userID) body := map[string]string{"cluster": clusterName} err = c.transport.Request(&res, http.MethodPost, "/1/clusters/mapping", body, call.Write, opts...) return }
go
func (c *Client) AssignUserID(userID, clusterName string, opts ...interface{}) (res AssignUserIDRes, err error) { opts = opt.InsertExtraHeader(opts, "X-Algolia-User-ID", userID) body := map[string]string{"cluster": clusterName} err = c.transport.Request(&res, http.MethodPost, "/1/clusters/mapping", body, call.Write, opts...) return }
[ "func", "(", "c", "*", "Client", ")", "AssignUserID", "(", "userID", ",", "clusterName", "string", ",", "opts", "...", "interface", "{", "}", ")", "(", "res", "AssignUserIDRes", ",", "err", "error", ")", "{", "opts", "=", "opt", ".", "InsertExtraHeader",...
// AssignUserID assign the given userID to the given cluster.
[ "AssignUserID", "assign", "the", "given", "userID", "to", "the", "given", "cluster", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/client_mcm.go#L37-L42
train
algolia/algoliasearch-client-go
algolia/search/client_mcm.go
RemoveUserID
func (c *Client) RemoveUserID(userID string, opts ...interface{}) (res RemoveUserIDRes, err error) { opts = opt.InsertExtraHeader(opts, "X-Algolia-User-ID", userID) err = c.transport.Request(&res, http.MethodDelete, "/1/clusters/mapping", nil, call.Write, opts...) return }
go
func (c *Client) RemoveUserID(userID string, opts ...interface{}) (res RemoveUserIDRes, err error) { opts = opt.InsertExtraHeader(opts, "X-Algolia-User-ID", userID) err = c.transport.Request(&res, http.MethodDelete, "/1/clusters/mapping", nil, call.Write, opts...) return }
[ "func", "(", "c", "*", "Client", ")", "RemoveUserID", "(", "userID", "string", ",", "opts", "...", "interface", "{", "}", ")", "(", "res", "RemoveUserIDRes", ",", "err", "error", ")", "{", "opts", "=", "opt", ".", "InsertExtraHeader", "(", "opts", ",",...
// RemoveUserID deletes the given userID managed by MCM.
[ "RemoveUserID", "deletes", "the", "given", "userID", "managed", "by", "MCM", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/client_mcm.go#L45-L49
train
algolia/algoliasearch-client-go
algolia/search/client_mcm.go
GetTopUserIDs
func (c *Client) GetTopUserIDs(opts ...interface{}) (res TopUserIDs, err error) { err = c.transport.Request(&res, "GET", "/1/clusters/mapping/top", nil, call.Read, opts...) return }
go
func (c *Client) GetTopUserIDs(opts ...interface{}) (res TopUserIDs, err error) { err = c.transport.Request(&res, "GET", "/1/clusters/mapping/top", nil, call.Read, opts...) return }
[ "func", "(", "c", "*", "Client", ")", "GetTopUserIDs", "(", "opts", "...", "interface", "{", "}", ")", "(", "res", "TopUserIDs", ",", "err", "error", ")", "{", "err", "=", "c", ".", "transport", ".", "Request", "(", "&", "res", ",", "\"GET\"", ",",...
// GetTopUserIDs retrieves the top list of userIDs managed by MCM.
[ "GetTopUserIDs", "retrieves", "the", "top", "list", "of", "userIDs", "managed", "by", "MCM", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/client_mcm.go#L52-L55
train
algolia/algoliasearch-client-go
algolia/opt/remove_words_if_no_results.go
RemoveWordsIfNoResultsEqual
func RemoveWordsIfNoResultsEqual(o1, o2 *RemoveWordsIfNoResultsOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func RemoveWordsIfNoResultsEqual(o1, o2 *RemoveWordsIfNoResultsOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "RemoveWordsIfNoResultsEqual", "(", "o1", ",", "o2", "*", "RemoveWordsIfNoResultsOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2...
// RemoveWordsIfNoResultsEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "RemoveWordsIfNoResultsEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/remove_words_if_no_results.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/internal/opt/query_languages.go
ExtractQueryLanguages
func ExtractQueryLanguages(opts ...interface{}) *opt.QueryLanguagesOption { for _, o := range opts { if v, ok := o.(*opt.QueryLanguagesOption); ok { return v } } return nil }
go
func ExtractQueryLanguages(opts ...interface{}) *opt.QueryLanguagesOption { for _, o := range opts { if v, ok := o.(*opt.QueryLanguagesOption); ok { return v } } return nil }
[ "func", "ExtractQueryLanguages", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "QueryLanguagesOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "QueryLanguag...
// ExtractQueryLanguages returns the first found QueryLanguagesOption from the // given variadic arguments or nil otherwise.
[ "ExtractQueryLanguages", "returns", "the", "first", "found", "QueryLanguagesOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/query_languages.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/search/client_personalization.go
SetPersonalizationStrategy
func (c *Client) SetPersonalizationStrategy(strategy Strategy, opts ...interface{}) (res SetPersonalizationStrategyRes, err error) { path := c.path("/recommendation/personalization/strategy") err = c.transport.Request(&res, http.MethodPost, path, strategy, call.Write, opts...) return }
go
func (c *Client) SetPersonalizationStrategy(strategy Strategy, opts ...interface{}) (res SetPersonalizationStrategyRes, err error) { path := c.path("/recommendation/personalization/strategy") err = c.transport.Request(&res, http.MethodPost, path, strategy, call.Write, opts...) return }
[ "func", "(", "c", "*", "Client", ")", "SetPersonalizationStrategy", "(", "strategy", "Strategy", ",", "opts", "...", "interface", "{", "}", ")", "(", "res", "SetPersonalizationStrategyRes", ",", "err", "error", ")", "{", "path", ":=", "c", ".", "path", "("...
// SetPersonalizationStrategy defines and override the full configuration of // the personalization strategy feature.
[ "SetPersonalizationStrategy", "defines", "and", "override", "the", "full", "configuration", "of", "the", "personalization", "strategy", "feature", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/client_personalization.go#L11-L15
train
algolia/algoliasearch-client-go
algolia/search/client_personalization.go
GetPersonalizationStrategy
func (c *Client) GetPersonalizationStrategy(opts ...interface{}) (res GetPersonalizationStrategyRes, err error) { path := c.path("/recommendation/personalization/strategy") err = c.transport.Request(&res, http.MethodGet, path, nil, call.Read, opts...) return }
go
func (c *Client) GetPersonalizationStrategy(opts ...interface{}) (res GetPersonalizationStrategyRes, err error) { path := c.path("/recommendation/personalization/strategy") err = c.transport.Request(&res, http.MethodGet, path, nil, call.Read, opts...) return }
[ "func", "(", "c", "*", "Client", ")", "GetPersonalizationStrategy", "(", "opts", "...", "interface", "{", "}", ")", "(", "res", "GetPersonalizationStrategyRes", ",", "err", "error", ")", "{", "path", ":=", "c", ".", "path", "(", "\"/recommendation/personalizat...
// GetPersonalizationStrategy retrieves the full configuration of the // personalization strategy feature.
[ "GetPersonalizationStrategy", "retrieves", "the", "full", "configuration", "of", "the", "personalization", "strategy", "feature", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/client_personalization.go#L19-L23
train
algolia/algoliasearch-client-go
algolia/opt/restrict_searchable_attributes.go
RestrictSearchableAttributesEqual
func RestrictSearchableAttributesEqual(o1, o2 *RestrictSearchableAttributesOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func RestrictSearchableAttributesEqual(o1, o2 *RestrictSearchableAttributesOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "RestrictSearchableAttributesEqual", "(", "o1", ",", "o2", "*", "RestrictSearchableAttributesOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "re...
// RestrictSearchableAttributesEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "RestrictSearchableAttributesEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/restrict_searchable_attributes.go#L58-L66
train
algolia/algoliasearch-client-go
algolia/opt/cluster_name.go
ClusterNameEqual
func ClusterNameEqual(o1, o2 *ClusterNameOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func ClusterNameEqual(o1, o2 *ClusterNameOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "ClusterNameEqual", "(", "o1", ",", "o2", "*", "ClusterNameOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "Equal", ...
// ClusterNameEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "ClusterNameEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", "de...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/cluster_name.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/search/client_multiple.go
MultipleBatch
func (c *Client) MultipleBatch(operations []BatchOperationIndexed, opts ...interface{}) (res MultipleBatchRes, err error) { body := map[string][]BatchOperationIndexed{"requests": operations} path := c.path("/indexes/*/batch") err = c.transport.Request(&res, http.MethodPost, path, body, call.Write, opts...) res.wait = c.waitTask return }
go
func (c *Client) MultipleBatch(operations []BatchOperationIndexed, opts ...interface{}) (res MultipleBatchRes, err error) { body := map[string][]BatchOperationIndexed{"requests": operations} path := c.path("/indexes/*/batch") err = c.transport.Request(&res, http.MethodPost, path, body, call.Write, opts...) res.wait = c.waitTask return }
[ "func", "(", "c", "*", "Client", ")", "MultipleBatch", "(", "operations", "[", "]", "BatchOperationIndexed", ",", "opts", "...", "interface", "{", "}", ")", "(", "res", "MultipleBatchRes", ",", "err", "error", ")", "{", "body", ":=", "map", "[", "string"...
// MultipleBatch applies multiple indexing operations on potentially multiple // indices in a single call.
[ "MultipleBatch", "applies", "multiple", "indexing", "operations", "on", "potentially", "multiple", "indices", "in", "a", "single", "call", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/client_multiple.go#L11-L17
train
algolia/algoliasearch-client-go
algolia/search/client_multiple.go
MultipleGetObjects
func (c *Client) MultipleGetObjects(requests []IndexedGetObject, objects interface{}, opts ...interface{}) (err error) { if len(requests) == 0 { return } res := getObjectsRes{objects} body := map[string]interface{}{"requests": requests} path := c.path("/indexes/*/objects") err = c.transport.Request(&res, http.MethodPost, path, body, call.Read, opts...) return }
go
func (c *Client) MultipleGetObjects(requests []IndexedGetObject, objects interface{}, opts ...interface{}) (err error) { if len(requests) == 0 { return } res := getObjectsRes{objects} body := map[string]interface{}{"requests": requests} path := c.path("/indexes/*/objects") err = c.transport.Request(&res, http.MethodPost, path, body, call.Read, opts...) return }
[ "func", "(", "c", "*", "Client", ")", "MultipleGetObjects", "(", "requests", "[", "]", "IndexedGetObject", ",", "objects", "interface", "{", "}", ",", "opts", "...", "interface", "{", "}", ")", "(", "err", "error", ")", "{", "if", "len", "(", "requests...
// MultipleGetObjects retrieves multiple objects from potentially multiple // indices in a single call.
[ "MultipleGetObjects", "retrieves", "multiple", "objects", "from", "potentially", "multiple", "indices", "in", "a", "single", "call", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/client_multiple.go#L25-L34
train
algolia/algoliasearch-client-go
algolia/search/client_multiple.go
MultipleQueries
func (c *Client) MultipleQueries(queries []IndexedQuery, strategy string, opts ...interface{}) (res MultipleQueriesRes, err error) { body := newMultipleQueriesReq(queries, strategy) path := c.path("/indexes/*/queries") err = c.transport.Request(&res, http.MethodPost, path, body, call.Read, opts...) return }
go
func (c *Client) MultipleQueries(queries []IndexedQuery, strategy string, opts ...interface{}) (res MultipleQueriesRes, err error) { body := newMultipleQueriesReq(queries, strategy) path := c.path("/indexes/*/queries") err = c.transport.Request(&res, http.MethodPost, path, body, call.Read, opts...) return }
[ "func", "(", "c", "*", "Client", ")", "MultipleQueries", "(", "queries", "[", "]", "IndexedQuery", ",", "strategy", "string", ",", "opts", "...", "interface", "{", "}", ")", "(", "res", "MultipleQueriesRes", ",", "err", "error", ")", "{", "body", ":=", ...
// MultipleQueries performs multiple search queries on potentially multiple // indices in a single call.
[ "MultipleQueries", "performs", "multiple", "search", "queries", "on", "potentially", "multiple", "indices", "in", "a", "single", "call", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/client_multiple.go#L38-L43
train
algolia/algoliasearch-client-go
algolia/internal/opt/attributes_to_highlight.go
ExtractAttributesToHighlight
func ExtractAttributesToHighlight(opts ...interface{}) *opt.AttributesToHighlightOption { for _, o := range opts { if v, ok := o.(*opt.AttributesToHighlightOption); ok { return v } } return nil }
go
func ExtractAttributesToHighlight(opts ...interface{}) *opt.AttributesToHighlightOption { for _, o := range opts { if v, ok := o.(*opt.AttributesToHighlightOption); ok { return v } } return nil }
[ "func", "ExtractAttributesToHighlight", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "AttributesToHighlightOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", ...
// ExtractAttributesToHighlight returns the first found AttributesToHighlightOption from the // given variadic arguments or nil otherwise.
[ "ExtractAttributesToHighlight", "returns", "the", "first", "found", "AttributesToHighlightOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/attributes_to_highlight.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/opt/around_lat_lng.go
AroundLatLngEqual
func AroundLatLngEqual(o1, o2 *AroundLatLngOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func AroundLatLngEqual(o1, o2 *AroundLatLngOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "AroundLatLngEqual", "(", "o1", ",", "o2", "*", "AroundLatLngOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "Equal",...
// AroundLatLngEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "AroundLatLngEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", "d...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/around_lat_lng.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/internal/opt/hits_per_page.go
ExtractHitsPerPage
func ExtractHitsPerPage(opts ...interface{}) *opt.HitsPerPageOption { for _, o := range opts { if v, ok := o.(*opt.HitsPerPageOption); ok { return v } } return nil }
go
func ExtractHitsPerPage(opts ...interface{}) *opt.HitsPerPageOption { for _, o := range opts { if v, ok := o.(*opt.HitsPerPageOption); ok { return v } } return nil }
[ "func", "ExtractHitsPerPage", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "HitsPerPageOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "HitsPerPageOption"...
// ExtractHitsPerPage returns the first found HitsPerPageOption from the // given variadic arguments or nil otherwise.
[ "ExtractHitsPerPage", "returns", "the", "first", "found", "HitsPerPageOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/hits_per_page.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/opt/hits_per_page.go
HitsPerPageEqual
func HitsPerPageEqual(o1, o2 *HitsPerPageOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func HitsPerPageEqual(o1, o2 *HitsPerPageOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "HitsPerPageEqual", "(", "o1", ",", "o2", "*", "HitsPerPageOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "Equal", ...
// HitsPerPageEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "HitsPerPageEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", "de...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/hits_per_page.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/internal/gen/gen_query_params.go
main
func main() { var ( settings []Option settingsTemplate = createTemplate("templates/query_params.go.tmpl") filepath = "../../search/query_params.go" ) for _, opt := range options { if isSearch(opt.Kind) { settings = append(settings, opt) } } generateFile(settingsTemplate, settings, filepath) }
go
func main() { var ( settings []Option settingsTemplate = createTemplate("templates/query_params.go.tmpl") filepath = "../../search/query_params.go" ) for _, opt := range options { if isSearch(opt.Kind) { settings = append(settings, opt) } } generateFile(settingsTemplate, settings, filepath) }
[ "func", "main", "(", ")", "{", "var", "(", "settings", "[", "]", "Option", "\n", "settingsTemplate", "=", "createTemplate", "(", "\"templates/query_params.go.tmpl\"", ")", "\n", "filepath", "=", "\"../../search/query_params.go\"", "\n", ")", "\n", "for", "_", ",...
// Generates the query_params.go file which contains the main QueryParams // struct used by Search and other methods.
[ "Generates", "the", "query_params", ".", "go", "file", "which", "contains", "the", "main", "QueryParams", "struct", "used", "by", "Search", "and", "other", "methods", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/gen/gen_query_params.go#L7-L21
train
algolia/algoliasearch-client-go
algolia/opt/minimum_around_radius.go
MinimumAroundRadiusEqual
func MinimumAroundRadiusEqual(o1, o2 *MinimumAroundRadiusOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func MinimumAroundRadiusEqual(o1, o2 *MinimumAroundRadiusOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "MinimumAroundRadiusEqual", "(", "o1", ",", "o2", "*", "MinimumAroundRadiusOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", "...
// MinimumAroundRadiusEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "MinimumAroundRadiusEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/minimum_around_radius.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/search/key.go
SetQueryParameters
func (k *Key) SetQueryParameters(opts ...interface{}) { k.QueryParameters = transport.URLEncode(newQueryParams(opts...)) }
go
func (k *Key) SetQueryParameters(opts ...interface{}) { k.QueryParameters = transport.URLEncode(newQueryParams(opts...)) }
[ "func", "(", "k", "*", "Key", ")", "SetQueryParameters", "(", "opts", "...", "interface", "{", "}", ")", "{", "k", ".", "QueryParameters", "=", "transport", ".", "URLEncode", "(", "newQueryParams", "(", "opts", "...", ")", ")", "\n", "}" ]
// SetQueryParameters properly encodes any given query parameters into the // QueryParameters field of the Key.
[ "SetQueryParameters", "properly", "encodes", "any", "given", "query", "parameters", "into", "the", "QueryParameters", "field", "of", "the", "Key", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/key.go#L29-L31
train
algolia/algoliasearch-client-go
algolia/search/key.go
Equal
func (k Key) Equal(k2 Key) bool { k.CreatedAt, k2.CreatedAt = time.Time{}, time.Time{} k.Validity, k2.Validity = 0, 0 return reflect.DeepEqual(k, k2) }
go
func (k Key) Equal(k2 Key) bool { k.CreatedAt, k2.CreatedAt = time.Time{}, time.Time{} k.Validity, k2.Validity = 0, 0 return reflect.DeepEqual(k, k2) }
[ "func", "(", "k", "Key", ")", "Equal", "(", "k2", "Key", ")", "bool", "{", "k", ".", "CreatedAt", ",", "k2", ".", "CreatedAt", "=", "time", ".", "Time", "{", "}", ",", "time", ".", "Time", "{", "}", "\n", "k", ".", "Validity", ",", "k2", ".",...
// Equal returns true if the Keys are equal. It returns false otherwise.
[ "Equal", "returns", "true", "if", "the", "Keys", "are", "equal", ".", "It", "returns", "false", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/search/key.go#L65-L69
train
algolia/algoliasearch-client-go
algolia/opt/index_name.go
IndexNameEqual
func IndexNameEqual(o1, o2 *IndexNameOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func IndexNameEqual(o1, o2 *IndexNameOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "IndexNameEqual", "(", "o1", ",", "o2", "*", "IndexNameOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "Equal", "("...
// IndexNameEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "IndexNameEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", "defa...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/index_name.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/internal/opt/attributes_to_snippet.go
ExtractAttributesToSnippet
func ExtractAttributesToSnippet(opts ...interface{}) *opt.AttributesToSnippetOption { for _, o := range opts { if v, ok := o.(*opt.AttributesToSnippetOption); ok { return v } } return nil }
go
func ExtractAttributesToSnippet(opts ...interface{}) *opt.AttributesToSnippetOption { for _, o := range opts { if v, ok := o.(*opt.AttributesToSnippetOption); ok { return v } } return nil }
[ "func", "ExtractAttributesToSnippet", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "AttributesToSnippetOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "At...
// ExtractAttributesToSnippet returns the first found AttributesToSnippetOption from the // given variadic arguments or nil otherwise.
[ "ExtractAttributesToSnippet", "returns", "the", "first", "found", "AttributesToSnippetOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/attributes_to_snippet.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/opt/user_token.go
UserTokenEqual
func UserTokenEqual(o1, o2 *UserTokenOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func UserTokenEqual(o1, o2 *UserTokenOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "UserTokenEqual", "(", "o1", ",", "o2", "*", "UserTokenOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "Equal", "("...
// UserTokenEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "UserTokenEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", "defa...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/user_token.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/internal/opt/safe.go
ExtractSafe
func ExtractSafe(opts ...interface{}) *opt.SafeOption { for _, o := range opts { if v, ok := o.(*opt.SafeOption); ok { return v } } return nil }
go
func ExtractSafe(opts ...interface{}) *opt.SafeOption { for _, o := range opts { if v, ok := o.(*opt.SafeOption); ok { return v } } return nil }
[ "func", "ExtractSafe", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "SafeOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "SafeOption", ")", ";", "ok...
// ExtractSafe returns the first found SafeOption from the // given variadic arguments or nil otherwise.
[ "ExtractSafe", "returns", "the", "first", "found", "SafeOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/safe.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/internal/opt/advanced_syntax.go
ExtractAdvancedSyntax
func ExtractAdvancedSyntax(opts ...interface{}) *opt.AdvancedSyntaxOption { for _, o := range opts { if v, ok := o.(*opt.AdvancedSyntaxOption); ok { return v } } return nil }
go
func ExtractAdvancedSyntax(opts ...interface{}) *opt.AdvancedSyntaxOption { for _, o := range opts { if v, ok := o.(*opt.AdvancedSyntaxOption); ok { return v } } return nil }
[ "func", "ExtractAdvancedSyntax", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "AdvancedSyntaxOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "AdvancedSynt...
// ExtractAdvancedSyntax returns the first found AdvancedSyntaxOption from the // given variadic arguments or nil otherwise.
[ "ExtractAdvancedSyntax", "returns", "the", "first", "found", "AdvancedSyntaxOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/advanced_syntax.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/internal/opt/facet_filters.go
ExtractFacetFilters
func ExtractFacetFilters(opts ...interface{}) *opt.FacetFiltersOption { for _, o := range opts { if v, ok := o.(*opt.FacetFiltersOption); ok { return v } } return nil }
go
func ExtractFacetFilters(opts ...interface{}) *opt.FacetFiltersOption { for _, o := range opts { if v, ok := o.(*opt.FacetFiltersOption); ok { return v } } return nil }
[ "func", "ExtractFacetFilters", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "FacetFiltersOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "FacetFiltersOpti...
// ExtractFacetFilters returns the first found FacetFiltersOption from the // given variadic arguments or nil otherwise.
[ "ExtractFacetFilters", "returns", "the", "first", "found", "FacetFiltersOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/facet_filters.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/opt/around_lat_lng_via_ip.go
AroundLatLngViaIPEqual
func AroundLatLngViaIPEqual(o1, o2 *AroundLatLngViaIPOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func AroundLatLngViaIPEqual(o1, o2 *AroundLatLngViaIPOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "AroundLatLngViaIPEqual", "(", "o1", ",", "o2", "*", "AroundLatLngViaIPOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", ...
// AroundLatLngViaIPEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "AroundLatLngViaIPEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the",...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/around_lat_lng_via_ip.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/internal/opt/limit.go
ExtractLimit
func ExtractLimit(opts ...interface{}) *opt.LimitOption { for _, o := range opts { if v, ok := o.(*opt.LimitOption); ok { return v } } return nil }
go
func ExtractLimit(opts ...interface{}) *opt.LimitOption { for _, o := range opts { if v, ok := o.(*opt.LimitOption); ok { return v } } return nil }
[ "func", "ExtractLimit", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "LimitOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "LimitOption", ")", ";", ...
// ExtractLimit returns the first found LimitOption from the // given variadic arguments or nil otherwise.
[ "ExtractLimit", "returns", "the", "first", "found", "LimitOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/limit.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/internal/opt/attributes_for_faceting.go
ExtractAttributesForFaceting
func ExtractAttributesForFaceting(opts ...interface{}) *opt.AttributesForFacetingOption { for _, o := range opts { if v, ok := o.(*opt.AttributesForFacetingOption); ok { return v } } return nil }
go
func ExtractAttributesForFaceting(opts ...interface{}) *opt.AttributesForFacetingOption { for _, o := range opts { if v, ok := o.(*opt.AttributesForFacetingOption); ok { return v } } return nil }
[ "func", "ExtractAttributesForFaceting", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "AttributesForFacetingOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", ...
// ExtractAttributesForFaceting returns the first found AttributesForFacetingOption from the // given variadic arguments or nil otherwise.
[ "ExtractAttributesForFaceting", "returns", "the", "first", "found", "AttributesForFacetingOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/attributes_for_faceting.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/internal/opt/create_if_not_exists.go
ExtractCreateIfNotExists
func ExtractCreateIfNotExists(opts ...interface{}) *opt.CreateIfNotExistsOption { for _, o := range opts { if v, ok := o.(*opt.CreateIfNotExistsOption); ok { return v } } return nil }
go
func ExtractCreateIfNotExists(opts ...interface{}) *opt.CreateIfNotExistsOption { for _, o := range opts { if v, ok := o.(*opt.CreateIfNotExistsOption); ok { return v } } return nil }
[ "func", "ExtractCreateIfNotExists", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "CreateIfNotExistsOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "Create...
// ExtractCreateIfNotExists returns the first found CreateIfNotExistsOption from the // given variadic arguments or nil otherwise.
[ "ExtractCreateIfNotExists", "returns", "the", "first", "found", "CreateIfNotExistsOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/create_if_not_exists.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/opt/enable_personalization.go
EnablePersonalizationEqual
func EnablePersonalizationEqual(o1, o2 *EnablePersonalizationOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func EnablePersonalizationEqual(o1, o2 *EnablePersonalizationOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "EnablePersonalizationEqual", "(", "o1", ",", "o2", "*", "EnablePersonalizationOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2",...
// EnablePersonalizationEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "EnablePersonalizationEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "t...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/enable_personalization.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/opt/create_if_not_exists.go
CreateIfNotExistsEqual
func CreateIfNotExistsEqual(o1, o2 *CreateIfNotExistsOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func CreateIfNotExistsEqual(o1, o2 *CreateIfNotExistsOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "CreateIfNotExistsEqual", "(", "o1", ",", "o2", "*", "CreateIfNotExistsOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", ...
// CreateIfNotExistsEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "CreateIfNotExistsEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the",...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/create_if_not_exists.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/internal/opt/allow_typos_on_numeric_tokens.go
ExtractAllowTyposOnNumericTokens
func ExtractAllowTyposOnNumericTokens(opts ...interface{}) *opt.AllowTyposOnNumericTokensOption { for _, o := range opts { if v, ok := o.(*opt.AllowTyposOnNumericTokensOption); ok { return v } } return nil }
go
func ExtractAllowTyposOnNumericTokens(opts ...interface{}) *opt.AllowTyposOnNumericTokensOption { for _, o := range opts { if v, ok := o.(*opt.AllowTyposOnNumericTokensOption); ok { return v } } return nil }
[ "func", "ExtractAllowTyposOnNumericTokens", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "AllowTyposOnNumericTokensOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ...
// ExtractAllowTyposOnNumericTokens returns the first found AllowTyposOnNumericTokensOption from the // given variadic arguments or nil otherwise.
[ "ExtractAllowTyposOnNumericTokens", "returns", "the", "first", "found", "AllowTyposOnNumericTokensOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/allow_typos_on_numeric_tokens.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/opt/facets.go
FacetsEqual
func FacetsEqual(o1, o2 *FacetsOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func FacetsEqual(o1, o2 *FacetsOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "FacetsEqual", "(", "o1", ",", "o2", "*", "FacetsOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "Equal", "(", "o...
// FacetsEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "FacetsEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", "default...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/facets.go#L58-L66
train
algolia/algoliasearch-client-go
algolia/opt/inside_bounding_box.go
MarshalJSON
func (o InsideBoundingBoxOption) MarshalJSON() ([]byte, error) { if o.coordinates != "" { return json.Marshal(o.coordinates) } return json.Marshal(o.boxes) }
go
func (o InsideBoundingBoxOption) MarshalJSON() ([]byte, error) { if o.coordinates != "" { return json.Marshal(o.coordinates) } return json.Marshal(o.boxes) }
[ "func", "(", "o", "InsideBoundingBoxOption", ")", "MarshalJSON", "(", ")", "(", "[", "]", "byte", ",", "error", ")", "{", "if", "o", ".", "coordinates", "!=", "\"\"", "{", "return", "json", ".", "Marshal", "(", "o", ".", "coordinates", ")", "\n", "}"...
// MarshalJSON implements the json.Marshaler interface for // InsideBoundingBoxOption.
[ "MarshalJSON", "implements", "the", "json", ".", "Marshaler", "interface", "for", "InsideBoundingBoxOption", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/inside_bounding_box.go#L39-L44
train
algolia/algoliasearch-client-go
algolia/opt/inside_bounding_box.go
UnmarshalJSON
func (o *InsideBoundingBoxOption) UnmarshalJSON(data []byte) error { if string(data) == "null" { return nil } var boxes [][4]float64 if err := json.Unmarshal(data, &boxes); err == nil { o.boxes = boxes return nil } var coordinates string if err := json.Unmarshal(data, &coordinates); err == nil { o.coordinates = coordinates return nil } return errs.ErrJSONDecode(data, "InsideBoundingBox") }
go
func (o *InsideBoundingBoxOption) UnmarshalJSON(data []byte) error { if string(data) == "null" { return nil } var boxes [][4]float64 if err := json.Unmarshal(data, &boxes); err == nil { o.boxes = boxes return nil } var coordinates string if err := json.Unmarshal(data, &coordinates); err == nil { o.coordinates = coordinates return nil } return errs.ErrJSONDecode(data, "InsideBoundingBox") }
[ "func", "(", "o", "*", "InsideBoundingBoxOption", ")", "UnmarshalJSON", "(", "data", "[", "]", "byte", ")", "error", "{", "if", "string", "(", "data", ")", "==", "\"null\"", "{", "return", "nil", "\n", "}", "\n", "var", "boxes", "[", "]", "[", "4", ...
// UnmarshalJSON implements the json.Unmarshaler interface for // InsideBoundingBoxOption.
[ "UnmarshalJSON", "implements", "the", "json", ".", "Unmarshaler", "interface", "for", "InsideBoundingBoxOption", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/inside_bounding_box.go#L48-L66
train
algolia/algoliasearch-client-go
algolia/opt/inside_bounding_box.go
InsideBoundingBoxEqual
func InsideBoundingBoxEqual(o1, o2 *InsideBoundingBoxOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func InsideBoundingBoxEqual(o1, o2 *InsideBoundingBoxOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "InsideBoundingBoxEqual", "(", "o1", ",", "o2", "*", "InsideBoundingBoxOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", ...
// InsideBoundingBoxEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "InsideBoundingBoxEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the",...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/inside_bounding_box.go#L81-L89
train
algolia/algoliasearch-client-go
algolia/opt/referers.go
ReferersEqual
func ReferersEqual(o1, o2 *ReferersOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func ReferersEqual(o1, o2 *ReferersOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "ReferersEqual", "(", "o1", ",", "o2", "*", "ReferersOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "Equal", "(", ...
// ReferersEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "ReferersEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", "defau...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/referers.go#L58-L66
train
algolia/algoliasearch-client-go
algolia/internal/opt/page.go
ExtractPage
func ExtractPage(opts ...interface{}) *opt.PageOption { for _, o := range opts { if v, ok := o.(*opt.PageOption); ok { return v } } return nil }
go
func ExtractPage(opts ...interface{}) *opt.PageOption { for _, o := range opts { if v, ok := o.(*opt.PageOption); ok { return v } } return nil }
[ "func", "ExtractPage", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "PageOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "PageOption", ")", ";", "ok...
// ExtractPage returns the first found PageOption from the // given variadic arguments or nil otherwise.
[ "ExtractPage", "returns", "the", "first", "found", "PageOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/page.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/opt/optional_words.go
OptionalWordsEqual
func OptionalWordsEqual(o1, o2 *OptionalWordsOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func OptionalWordsEqual(o1, o2 *OptionalWordsOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "OptionalWordsEqual", "(", "o1", ",", "o2", "*", "OptionalWordsOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "Equal...
// OptionalWordsEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "OptionalWordsEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", "...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/optional_words.go#L58-L66
train
algolia/algoliasearch-client-go
algolia/opt/attributes_to_snippet.go
AttributesToSnippetEqual
func AttributesToSnippetEqual(o1, o2 *AttributesToSnippetOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func AttributesToSnippetEqual(o1, o2 *AttributesToSnippetOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "AttributesToSnippetEqual", "(", "o1", ",", "o2", "*", "AttributesToSnippetOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", "...
// AttributesToSnippetEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "AttributesToSnippetEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/attributes_to_snippet.go#L58-L66
train
algolia/algoliasearch-client-go
algolia/internal/opt/filters.go
ExtractFilters
func ExtractFilters(opts ...interface{}) *opt.FiltersOption { for _, o := range opts { if v, ok := o.(*opt.FiltersOption); ok { return v } } return nil }
go
func ExtractFilters(opts ...interface{}) *opt.FiltersOption { for _, o := range opts { if v, ok := o.(*opt.FiltersOption); ok { return v } } return nil }
[ "func", "ExtractFilters", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "FiltersOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "FiltersOption", ")", "...
// ExtractFilters returns the first found FiltersOption from the // given variadic arguments or nil otherwise.
[ "ExtractFilters", "returns", "the", "first", "found", "FiltersOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/filters.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/internal/opt/restrict_highlight_and_snippet_arrays.go
ExtractRestrictHighlightAndSnippetArrays
func ExtractRestrictHighlightAndSnippetArrays(opts ...interface{}) *opt.RestrictHighlightAndSnippetArraysOption { for _, o := range opts { if v, ok := o.(*opt.RestrictHighlightAndSnippetArraysOption); ok { return v } } return nil }
go
func ExtractRestrictHighlightAndSnippetArrays(opts ...interface{}) *opt.RestrictHighlightAndSnippetArraysOption { for _, o := range opts { if v, ok := o.(*opt.RestrictHighlightAndSnippetArraysOption); ok { return v } } return nil }
[ "func", "ExtractRestrictHighlightAndSnippetArrays", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "RestrictHighlightAndSnippetArraysOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", ...
// ExtractRestrictHighlightAndSnippetArrays returns the first found RestrictHighlightAndSnippetArraysOption from the // given variadic arguments or nil otherwise.
[ "ExtractRestrictHighlightAndSnippetArrays", "returns", "the", "first", "found", "RestrictHighlightAndSnippetArraysOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/restrict_highlight_and_snippet_arrays.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/opt/query.go
QueryEqual
func QueryEqual(o1, o2 *QueryOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func QueryEqual(o1, o2 *QueryOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "QueryEqual", "(", "o1", ",", "o2", "*", "QueryOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", "Equal", "(", "o1"...
// QueryEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "QueryEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the", "default"...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/query.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/internal/opt/length.go
ExtractLength
func ExtractLength(opts ...interface{}) *opt.LengthOption { for _, o := range opts { if v, ok := o.(*opt.LengthOption); ok { return v } } return nil }
go
func ExtractLength(opts ...interface{}) *opt.LengthOption { for _, o := range opts { if v, ok := o.(*opt.LengthOption); ok { return v } } return nil }
[ "func", "ExtractLength", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "LengthOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", "LengthOption", ")", ";",...
// ExtractLength returns the first found LengthOption from the // given variadic arguments or nil otherwise.
[ "ExtractLength", "returns", "the", "first", "found", "LengthOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/length.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/internal/opt/faceting_after_distinct.go
ExtractFacetingAfterDistinct
func ExtractFacetingAfterDistinct(opts ...interface{}) *opt.FacetingAfterDistinctOption { for _, o := range opts { if v, ok := o.(*opt.FacetingAfterDistinctOption); ok { return v } } return nil }
go
func ExtractFacetingAfterDistinct(opts ...interface{}) *opt.FacetingAfterDistinctOption { for _, o := range opts { if v, ok := o.(*opt.FacetingAfterDistinctOption); ok { return v } } return nil }
[ "func", "ExtractFacetingAfterDistinct", "(", "opts", "...", "interface", "{", "}", ")", "*", "opt", ".", "FacetingAfterDistinctOption", "{", "for", "_", ",", "o", ":=", "range", "opts", "{", "if", "v", ",", "ok", ":=", "o", ".", "(", "*", "opt", ".", ...
// ExtractFacetingAfterDistinct returns the first found FacetingAfterDistinctOption from the // given variadic arguments or nil otherwise.
[ "ExtractFacetingAfterDistinct", "returns", "the", "first", "found", "FacetingAfterDistinctOption", "from", "the", "given", "variadic", "arguments", "or", "nil", "otherwise", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/internal/opt/faceting_after_distinct.go#L11-L18
train
algolia/algoliasearch-client-go
algolia/opt/max_values_per_facet.go
MaxValuesPerFacetEqual
func MaxValuesPerFacetEqual(o1, o2 *MaxValuesPerFacetOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
go
func MaxValuesPerFacetEqual(o1, o2 *MaxValuesPerFacetOption) bool { if o1 != nil { return o1.Equal(o2) } if o2 != nil { return o2.Equal(o1) } return true }
[ "func", "MaxValuesPerFacetEqual", "(", "o1", ",", "o2", "*", "MaxValuesPerFacetOption", ")", "bool", "{", "if", "o1", "!=", "nil", "{", "return", "o1", ".", "Equal", "(", "o2", ")", "\n", "}", "\n", "if", "o2", "!=", "nil", "{", "return", "o2", ".", ...
// MaxValuesPerFacetEqual returns true if the two options are equal. // In case of one option being nil, the value of the other must be nil as well // or be set to the default value of this option.
[ "MaxValuesPerFacetEqual", "returns", "true", "if", "the", "two", "options", "are", "equal", ".", "In", "case", "of", "one", "option", "being", "nil", "the", "value", "of", "the", "other", "must", "be", "nil", "as", "well", "or", "be", "set", "to", "the",...
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/opt/max_values_per_facet.go#L55-L63
train
algolia/algoliasearch-client-go
algolia/insights/client.go
NewClientWithConfig
func NewClientWithConfig(config Configuration) *Client { var hosts []*transport.StatefulHost if config.Hosts == nil { hosts = defaultHosts(config.Region) } else { for _, h := range config.Hosts { hosts = append(hosts, transport.NewStatefulHost(h, call.IsReadWrite)) } } return &Client{ appID: config.AppID, transport: transport.New( hosts, config.Requester, config.AppID, config.APIKey, config.ReadTimeout, config.WriteTimeout, config.Headers, config.ExtraUserAgent, ), } }
go
func NewClientWithConfig(config Configuration) *Client { var hosts []*transport.StatefulHost if config.Hosts == nil { hosts = defaultHosts(config.Region) } else { for _, h := range config.Hosts { hosts = append(hosts, transport.NewStatefulHost(h, call.IsReadWrite)) } } return &Client{ appID: config.AppID, transport: transport.New( hosts, config.Requester, config.AppID, config.APIKey, config.ReadTimeout, config.WriteTimeout, config.Headers, config.ExtraUserAgent, ), } }
[ "func", "NewClientWithConfig", "(", "config", "Configuration", ")", "*", "Client", "{", "var", "hosts", "[", "]", "*", "transport", ".", "StatefulHost", "\n", "if", "config", ".", "Hosts", "==", "nil", "{", "hosts", "=", "defaultHosts", "(", "config", ".",...
// NewClientWithConfig instantiates a new client able to interact with the // Algolia Insights API.
[ "NewClientWithConfig", "instantiates", "a", "new", "client", "able", "to", "interact", "with", "the", "Algolia", "Insights", "API", "." ]
dc059c0414d8c06e2b2bb47412b2130799bfcc9f
https://github.com/algolia/algoliasearch-client-go/blob/dc059c0414d8c06e2b2bb47412b2130799bfcc9f/algolia/insights/client.go#L29-L53
train