Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Aggregator ¶
type Aggregator[T any] struct { // contains filtered or unexported fields }
func NewAggregator ¶
func NewAggregator[T any](collection *mongo.Collection) *Aggregator[T]
func (*Aggregator[T]) Aggregate ¶ added in v0.0.10
func (a *Aggregator[T]) Aggregate(ctx context.Context, opts ...*options.AggregateOptions) ([]*T, error)
func (*Aggregator[T]) AggregateWithParse ¶ added in v0.11.0
func (a *Aggregator[T]) AggregateWithParse(ctx context.Context, result any, opts ...*options.AggregateOptions) error
AggregateWithParse is used to parse the result of the aggregation result must be a pointer to a slice
func (*Aggregator[T]) Pipeline ¶
func (a *Aggregator[T]) Pipeline(pipeline any) *Aggregator[T]
type IAggregator ¶ added in v1.7.0
Click to show internal directories.
Click to hide internal directories.