Class: Couchbase::Collection::MutateInOptions
- Inherits:
-
Couchbase::CommonOptions
- Object
- Couchbase::CommonOptions
- Couchbase::Collection::MutateInOptions
- Defined in:
- lib/couchbase/collection_options.rb
Instance Attribute Summary collapse
-
#access_deleted ⇒ Boolean
For internal use only: allows access to deleted documents that are in 'tombstone' form.
-
#cas ⇒ Integer
Specifies a CAS value that will be taken into account on the server side for optimistic concurrency.
-
#create_as_deleted ⇒ Boolean
For internal use only: allows creating documents in 'tombstone' form.
-
#durability_level ⇒ :none, ...
Level of durability.
-
#expiry ⇒ Integer
Expiration time to associate with the document.
-
#store_semantics ⇒ :replace, ...
Describes how the outer document store semantics on subdoc should act.
-
#transcoder ⇒ Object
Returns the value of attribute transcoder.
Attributes inherited from Couchbase::CommonOptions
#client_context, #parent_span, #retry_strategy, #timeout
Instance Method Summary collapse
-
#initialize {|| ... } ⇒ MutateInOptions
constructor
A new instance of MutateInOptions.
Constructor Details
#initialize {|| ... } ⇒ MutateInOptions
Returns a new instance of MutateInOptions.
359 360 361 362 363 364 |
# File 'lib/couchbase/collection_options.rb', line 359 def initialize @durability_level = :none @store_semantics = :replace @transcoder = JsonTranscoder.new yield self if block_given? end |
Instance Attribute Details
#access_deleted ⇒ Boolean
Returns For internal use only: allows access to deleted documents that are in 'tombstone' form.
350 351 352 |
# File 'lib/couchbase/collection_options.rb', line 350 def access_deleted @access_deleted end |
#cas ⇒ Integer
Returns Specifies a CAS value that will be taken into account on the server side for optimistic concurrency.
347 348 349 |
# File 'lib/couchbase/collection_options.rb', line 347 def cas @cas end |
#create_as_deleted ⇒ Boolean
Returns For internal use only: allows creating documents in 'tombstone' form.
353 354 355 |
# File 'lib/couchbase/collection_options.rb', line 353 def create_as_deleted @create_as_deleted end |
#durability_level ⇒ :none, ...
Returns level of durability.
356 357 358 |
# File 'lib/couchbase/collection_options.rb', line 356 def durability_level @durability_level end |
#expiry ⇒ Integer
Returns expiration time to associate with the document.
335 336 337 |
# File 'lib/couchbase/collection_options.rb', line 335 def expiry @expiry end |
#store_semantics ⇒ :replace, ...
Describes how the outer document store semantics on subdoc should act
-
:replace
: replace the document, fail if it does not exist. This is the default -
:upsert
: replace the document or create if it does not exist -
:insert
: create the document, fail if it exists
344 345 346 |
# File 'lib/couchbase/collection_options.rb', line 344 def store_semantics @store_semantics end |
#transcoder ⇒ Object
Returns the value of attribute transcoder.
366 367 368 |
# File 'lib/couchbase/collection_options.rb', line 366 def transcoder @transcoder end |