Documentation ¶
Index ¶
- type Count
- type CountBundle
- func (cb *CountBundle) Collation(c *mongoopt.Collation) *CountBundle
- func (cb *CountBundle) ConvertCountOption() option.CountOptioner
- func (cb *CountBundle) Hint(hint interface{}) *CountBundle
- func (cb *CountBundle) Limit(i int64) *CountBundle
- func (cb *CountBundle) MaxTimeMs(i int32) *CountBundle
- func (cb *CountBundle) Skip(i int64) *CountBundle
- func (cb *CountBundle) String() string
- func (cb *CountBundle) Unbundle(deduplicate bool) ([]option.CountOptioner, *session.Client, error)
- type CountOption
- type CountSession
- type CountSessionOpt
- type EstimatedDocumentCount
- type EstimatedDocumentCountBundle
- func (cb *EstimatedDocumentCountBundle) ConvertEstimateDocumentCountOption() option.CountOptioner
- func (cb *EstimatedDocumentCountBundle) MaxTimeMs(i int32) *EstimatedDocumentCountBundle
- func (cb *EstimatedDocumentCountBundle) Unbundle(deduplicate bool) ([]option.CountOptioner, *session.Client, error)
- type EstimatedDocumentCountOption
- type EstimatedDocumentCountSession
- type OptCollation
- type OptHint
- type OptLimit
- type OptMaxTimeMs
- type OptSkip
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Count ¶
type Count interface {
// contains filtered or unexported methods
}
Count represents all passable params for the count() function.
type CountBundle ¶
type CountBundle struct {
// contains filtered or unexported fields
}
CountBundle is a bundle of Count options
func (*CountBundle) Collation ¶
func (cb *CountBundle) Collation(c *mongoopt.Collation) *CountBundle
Collation specifies a collation.
func (*CountBundle) ConvertCountOption ¶
func (cb *CountBundle) ConvertCountOption() option.CountOptioner
ConvertCountOption implements the Count interface
func (*CountBundle) Hint ¶
func (cb *CountBundle) Hint(hint interface{}) *CountBundle
Hint adds an option to specify the index to use.
func (*CountBundle) Limit ¶
func (cb *CountBundle) Limit(i int64) *CountBundle
Limit adds an option to limit the maximum number of documents to count.
func (*CountBundle) MaxTimeMs ¶
func (cb *CountBundle) MaxTimeMs(i int32) *CountBundle
MaxTimeMs adds an option to specify the maximum amount of time to allow the operation to run.
func (*CountBundle) Skip ¶
func (cb *CountBundle) Skip(i int64) *CountBundle
Skip adds an option to specify the number of documents to skip before counting.
func (*CountBundle) String ¶
func (cb *CountBundle) String() string
String implements the Stringer interface
func (*CountBundle) Unbundle ¶
func (cb *CountBundle) Unbundle(deduplicate bool) ([]option.CountOptioner, *session.Client, error)
Unbundle transforms a bundle into a slice of options, optionally deduplicating.
type CountOption ¶ added in v0.0.10
type CountOption interface { Count ConvertCountOption() option.CountOptioner }
CountOption represents the options for the count() function.
type CountSession ¶ added in v0.0.10
CountSession is the session for the count() function
type CountSessionOpt ¶ added in v0.0.10
type CountSessionOpt struct{}
CountSessionOpt is an count session option.
func (CountSessionOpt) ConvertCountSession ¶ added in v0.0.10
func (CountSessionOpt) ConvertCountSession() *session.Client
ConvertCountSession implements the CountSession interface.
type EstimatedDocumentCount ¶ added in v0.0.11
type EstimatedDocumentCount interface {
// contains filtered or unexported methods
}
EstimatedDocumentCount represents all passable params for the estimatedDocumentCount() function
type EstimatedDocumentCountBundle ¶ added in v0.0.11
type EstimatedDocumentCountBundle struct {
// contains filtered or unexported fields
}
EstimatedDocumentCountBundle is a bundle of EstimatedDocumentCount options
func BundleEstimatedDocumentCount ¶ added in v0.0.11
func BundleEstimatedDocumentCount(opts ...EstimatedDocumentCount) *EstimatedDocumentCountBundle
BundleEstimatedDocumentCount bundles EstimatedDocumentCount options
func (*EstimatedDocumentCountBundle) ConvertEstimateDocumentCountOption ¶ added in v0.0.11
func (cb *EstimatedDocumentCountBundle) ConvertEstimateDocumentCountOption() option.CountOptioner
ConvertEstimateDocumentCountOption implements the EstimatedDocumentCount interface
func (*EstimatedDocumentCountBundle) MaxTimeMs ¶ added in v0.0.11
func (cb *EstimatedDocumentCountBundle) MaxTimeMs(i int32) *EstimatedDocumentCountBundle
MaxTimeMs adds an option to specify the maximum amount of time to allow the operation to run.
func (*EstimatedDocumentCountBundle) Unbundle ¶ added in v0.0.11
func (cb *EstimatedDocumentCountBundle) Unbundle(deduplicate bool) ([]option.CountOptioner, *session.Client, error)
Unbundle transforms a bundle into a slice of options, optionally deduplicating.
type EstimatedDocumentCountOption ¶ added in v0.0.11
type EstimatedDocumentCountOption interface { EstimatedDocumentCount ConvertEstimateDocumentCountOption() option.CountOptioner }
EstimatedDocumentCountOption is options for the estimatedDocumentCount() function
type EstimatedDocumentCountSession ¶ added in v0.0.11
type EstimatedDocumentCountSession interface { EstimatedDocumentCount ConvertEstimateDocumentCountSession() *session.Client }
EstimatedDocumentCountSession is the session for the estimatedDocumentCount() function
type OptCollation ¶
type OptCollation option.OptCollation
OptCollation specifies a collation.
func Collation ¶
func Collation(collation *mongoopt.Collation) OptCollation
Collation specifies a Collation.
func (OptCollation) ConvertCountOption ¶
func (opt OptCollation) ConvertCountOption() option.CountOptioner
ConvertCountOption implements the Count interface.
type OptHint ¶
OptHint specifies the index to use.
func (OptHint) ConvertCountOption ¶
func (opt OptHint) ConvertCountOption() option.CountOptioner
ConvertCountOption implements the Count interface.
type OptLimit ¶
OptLimit limits the maximum number of documents to count.
func (OptLimit) ConvertCountOption ¶
func (opt OptLimit) ConvertCountOption() option.CountOptioner
ConvertCountOption implements the Count interface.
type OptMaxTimeMs ¶
type OptMaxTimeMs option.OptMaxTime
OptMaxTimeMs specifies the maximum amount of time to allow the operation to run.
func MaxTimeMs ¶
func MaxTimeMs(i int32) OptMaxTimeMs
MaxTimeMs specifies the maximum amount of time to allow the operation to run.
func (OptMaxTimeMs) ConvertCountOption ¶
func (opt OptMaxTimeMs) ConvertCountOption() option.CountOptioner
ConvertCountOption implements the Count interface.
func (OptMaxTimeMs) ConvertEstimateDocumentCountOption ¶ added in v0.0.11
func (opt OptMaxTimeMs) ConvertEstimateDocumentCountOption() option.CountOptioner
ConvertEstimateDocumentCountOption implements the Count interface.
type OptSkip ¶
OptSkip specifies the number of documents to skip before counting.
func (OptSkip) ConvertCountOption ¶
func (opt OptSkip) ConvertCountOption() option.CountOptioner
ConvertCountOption implements the Count interface.