Skip to content

opensavvy.ktmongo.dsl.options

Types

AbstractCompoundOption

abstract class AbstractCompoundOption(
    name: String, 
    content: BsonNode, 
    context: BsonContext
) : AbstractOption

Utility to easily implement options that contain a document as content.

AbstractOption

abstract class AbstractOption(val name: String, context: BsonContext) : AbstractBsonNode, Option

Helper to implement Option.

ArrayFiltersOption

Specifies which array elements should be updated by UpdateQuery.filter.

ArrayFiltersOptionDsl

BypassDocumentValidationOption

class BypassDocumentValidationOption(val bypassDocumentValidation: Boolean, context: BsonContext) : AbstractOption

Whether this operation is allowed to bypass document validation.

CappedMaxOption

class CappedMaxOption(val max: Long, context: BsonContext) : AbstractOption

The maximum number of documents in a capped collection.

CappedOption

class CappedOption(val capped: Boolean, context: BsonContext) : AbstractOption

Whether this collection is a capped collection.

CappedSizeOption

class CappedSizeOption(val sizeBytes: Long, context: BsonContext) : AbstractOption

The maximum size of a capped collection.

CommentOption

User-defined message associated with an operation, which is repeated in the logs.

HasArrayFilters

interface HasArrayFilters : Options

Specifies which array elements should be updated by UpdateQuery.filter.

HasBypassDocumentValidation

Whether this operation is allowed to bypass document validation.

HasCapped

interface HasCapped : Options

Whether this collection is a capped collection.

HasComment

interface HasComment : Options

User-defined message associated with an operation, which is repeated in the logs.

HasLimit

interface HasLimit : Options

Limits the number of elements returned by a query.

HasMaxTime

interface HasMaxTime : Options

Maximum duration spent processing the request.

HasOrdered

interface HasOrdered : Options

Specifies whether operations in a bulk are independent.

HasReadConcern

interface HasReadConcern : Options

Consistency guarantees for this request.

HasReadPreference

Declares which nodes should receive the request.

HasSkip

interface HasSkip : Options

Number of documents to skip before processing the request.

HasSort

interface HasSort<Document : Any> : Options

Describes in which order elements should be returned by the query.

HasValidation

Specifies validation rules for documents in a collection.

HasWriteConcern

interface HasWriteConcern : Options

Consistency guarantees for this request.

LimitOption

class LimitOption(val limit: Long, context: BsonContext) : AbstractOption

Maximum number of elements analyzed by this operation.

MaxTimeOption

class MaxTimeOption(val timeout: Duration, context: BsonContext) : AbstractOption

Maximum timeout spent processing the request.

Option

interface Option : BsonNode

Additional parameters that are passed to MongoDB operations.

Options

Parent interface for all option containers.

OrderedOption

class OrderedOption(val ordered: Boolean, context: BsonContext) : AbstractOption

Whether the operations in this bulk are independent.

ReadConcern

The read concern allows configuring the level of consistency required for each operation.

ReadConcernOption

class ReadConcernOption(val concern: ReadConcern, context: BsonContext) : AbstractOption

Specifies the read concern for an operation.

ReadPreference

The read preference allows configuring which instance the request will be sent to.

ReadPreferenceOption

Specifies the read preference for an operation.

SkipOption

class SkipOption(val skip: Long, context: BsonContext) : AbstractOption

Number of documents to skip before processing the request.

SortOption

Describes in which order elements should be returned.

SortOptionDsl

DSL to describe a sort order.

ValidationAction

Specifies how MongoDB reacts when a document doesn't pass validation.

ValidationActionOption

Specifies the validation action in a collection.

ValidationLevel

Specifies how strictly MongoDB applies the validation rules.

ValidationLevelOption

Specifies the validation level in a collection.

ValidatorOption

class ValidatorOption(val validator: BsonNode, context: BsonContext) : AbstractOption

Specifies a validator for documents in a collection.

WriteAcknowledgment

sealed class WriteAcknowledgment

Describes how many nodes must acknowledge this write operation.

WriteConcern

class WriteConcern(
    val acknowledgment: WriteAcknowledgment? = null, 
    val writeToJournal: Boolean? = null, 
    val writeTimeout: Duration? = null
)

The level of acknowledgment requested from a write operation.

WriteConcernOption

class WriteConcernOption(val concern: WriteConcern, context: BsonContext) : AbstractOption

Specifies the write concern for an operation.

Functions