Skip to content

Commit

Permalink
Comment fixups
Browse files Browse the repository at this point in the history
  • Loading branch information
ehershey authored and skriptble committed Mar 13, 2019
1 parent a7eb0f4 commit 8f37256
Show file tree
Hide file tree
Showing 11 changed files with 18 additions and 18 deletions.
2 changes: 1 addition & 1 deletion mongo/index_view.go
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ func (iv IndexView) CreateOne(ctx context.Context, model IndexModel, opts ...*op
}

// CreateMany creates multiple indexes in the collection specified by the models. The names of the
// creates indexes are returned.
// created indexes are returned.
func (iv IndexView) CreateMany(ctx context.Context, models []IndexModel, opts ...*options.CreateIndexesOptions) ([]string, error) {
names := make([]string, 0, len(models))
indexes := bsonx.Arr{}
Expand Down
2 changes: 1 addition & 1 deletion mongo/options/aggregateoptions.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ package options

import "time"

// AggregateOptions represents all possible options to the aggregate() function
// AggregateOptions represents all possible options to the Aggregate() function.
type AggregateOptions struct {
AllowDiskUse *bool // Enables writing to temporary files. When set to true, aggregation stages can write data to the _tmp subdirectory in the dbPath directory
BatchSize *int32 // The number of documents to return per batch
Expand Down
2 changes: 1 addition & 1 deletion mongo/options/countoptions.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ package options

import "time"

// CountOptions represents all possible options to the count() function
// CountOptions represents all possible options to the Count() function.
type CountOptions struct {
Collation *Collation // Specifies a collation
Hint interface{} // The index to use
Expand Down
2 changes: 1 addition & 1 deletion mongo/options/deleteoptions.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

package options

// DeleteOptions represents all possible options to the deleteOne() and deleteMany() functions
// DeleteOptions represents all possible options to the DeleteOne() and DeleteMany() functions.
type DeleteOptions struct {
Collation *Collation // Specifies a collation
}
Expand Down
2 changes: 1 addition & 1 deletion mongo/options/distinctoptions.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ package options

import "time"

// DistinctOptions represents all possible options to the distinct() function
// DistinctOptions represents all possible options to the Distinct() function.
type DistinctOptions struct {
Collation *Collation // Specifies a collation
MaxTime *time.Duration // The maximum amount of time to allow the operation to run
Expand Down
2 changes: 1 addition & 1 deletion mongo/options/estimatedcountoptions.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ package options

import "time"

// EstimatedDocumentCountOptions represents all possible options to the estimatedDocumentCount() function
// EstimatedDocumentCountOptions represents all possible options to the EstimatedDocumentCount() function.
type EstimatedDocumentCountOptions struct {
MaxTime *time.Duration // The maximum amount of time to allow the operation to run
}
Expand Down
10 changes: 5 additions & 5 deletions mongo/options/findoptions.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
"time"
)

// FindOptions represent all possible options to the find() function.
// FindOptions represent all possible options to the Find() function.
type FindOptions struct {
AllowPartialResults *bool // If true, allows partial results to be returned if some shards are down.
BatchSize *int32 // Specifies the number of documents to return in every batch.
Expand Down Expand Up @@ -230,7 +230,7 @@ func MergeFindOptions(opts ...*FindOptions) *FindOptions {
return fo
}

// FindOneOptions represent all possible options to the findOne() function.
// FindOneOptions represent all possible options to the FindOne() function.
type FindOneOptions struct {
AllowPartialResults *bool // If true, allows partial results to be returned if some shards are down.
BatchSize *int32 // Specifies the number of documents to return in every batch.
Expand Down Expand Up @@ -433,7 +433,7 @@ func MergeFindOneOptions(opts ...*FindOneOptions) *FindOneOptions {
return fo
}

// FindOneAndReplaceOptions represent all possible options to the findOne() function.
// FindOneAndReplaceOptions represent all possible options to the FindOneAndReplace() function.
type FindOneAndReplaceOptions struct {
BypassDocumentValidation *bool // If true, allows the write to opt out of document-level validation.
Collation *Collation // Specifies a collation to be used
Expand Down Expand Up @@ -527,7 +527,7 @@ func MergeFindOneAndReplaceOptions(opts ...*FindOneAndReplaceOptions) *FindOneAn
return fo
}

// FindOneAndUpdateOptions represent all possible options to the findOne() function.
// FindOneAndUpdateOptions represent all possible options to the FindOneAndUpdate() function.
type FindOneAndUpdateOptions struct {
ArrayFilters *ArrayFilters // A set of filters specifying to which array elements an update should apply.
BypassDocumentValidation *bool // If true, allows the write to opt out of document-level validation.
Expand Down Expand Up @@ -630,7 +630,7 @@ func MergeFindOneAndUpdateOptions(opts ...*FindOneAndUpdateOptions) *FindOneAndU
return fo
}

// FindOneAndDeleteOptions represent all possible options to the findOne() function.
// FindOneAndDeleteOptions represent all possible options to the FindOneAndDelete() function.
type FindOneAndDeleteOptions struct {
Collation *Collation // Specifies a collation to be used
MaxTime *time.Duration // Specifies the maximum amount of time to allow the query to run.
Expand Down
6 changes: 3 additions & 3 deletions mongo/options/indexoptions.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
"time"
)

// CreateIndexesOptions represents all possible options for the create() function.
// CreateIndexesOptions represents all possible options for the CreateOne() and CreateMany() functions.
type CreateIndexesOptions struct {
MaxTime *time.Duration // The maximum amount of time to allow the query to run.
}
Expand Down Expand Up @@ -42,7 +42,7 @@ func MergeCreateIndexesOptions(opts ...*CreateIndexesOptions) *CreateIndexesOpti
return c
}

// DropIndexesOptions represents all possible options for the create() function.
// DropIndexesOptions represents all possible options for the DropIndexes() function.
type DropIndexesOptions struct {
MaxTime *time.Duration
}
Expand Down Expand Up @@ -74,7 +74,7 @@ func MergeDropIndexesOptions(opts ...*DropIndexesOptions) *DropIndexesOptions {
return c
}

// ListIndexesOptions represents all possible options for the create() function.
// ListIndexesOptions represents all possible options for the ListIndexes() function.
type ListIndexesOptions struct {
BatchSize *int32
MaxTime *time.Duration
Expand Down
4 changes: 2 additions & 2 deletions mongo/options/insertoptions.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

package options

// InsertOneOptions represents all possible options to the insertOne()
// InsertOneOptions represents all possible options to the InsertOne() function.
type InsertOneOptions struct {
BypassDocumentValidation *bool // If true, allows the write to opt-out of document level validation
}
Expand Down Expand Up @@ -38,7 +38,7 @@ func MergeInsertOneOptions(opts ...*InsertOneOptions) *InsertOneOptions {
return ioOpts
}

// InsertManyOptions represents all possible options to the insertMany()
// InsertManyOptions represents all possible options to the InsertMany() function.
type InsertManyOptions struct {
BypassDocumentValidation *bool // If true, allows the write to opt-out of document level validation
Ordered *bool // If true, when an insert fails, return without performing the remaining inserts. Defaults to true.
Expand Down
2 changes: 1 addition & 1 deletion mongo/options/replaceoptions.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

package options

// ReplaceOptions represents all possible options to the replaceOne() function
// ReplaceOptions represents all possible options to the ReplaceOne() function.
type ReplaceOptions struct {
BypassDocumentValidation *bool // If true, allows the write to opt-out of document level validation
Collation *Collation // Specifies a collation
Expand Down
2 changes: 1 addition & 1 deletion mongo/options/updateoptions.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

package options

// UpdateOptions represents all possible options to the updateOne() and updateMany() functions
// UpdateOptions represents all possible options to the UpdateOne() and UpdateMany() functions.
type UpdateOptions struct {
ArrayFilters *ArrayFilters // A set of filters specifying to which array elements an update should apply
BypassDocumentValidation *bool // If true, allows the write to opt-out of document level validation
Expand Down

0 comments on commit 8f37256

Please sign in to comment.