Class: Couchbase::Collection::MutateInOptions
- Inherits:
-
Couchbase::CommonOptions
- Object
- Couchbase::CommonOptions
- Couchbase::Collection::MutateInOptions
- Defined in:
- lib/couchbase/collection_options.rb,
/Users/sergey.auseyau/code/couchbase-ruby-client/lib/couchbase/collection_options.rb more...
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.
371 372 373 374 375 376 377 |
# File 'lib/couchbase/collection_options.rb', line 371 def initialize super @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.
362 363 364 |
# File 'lib/couchbase/collection_options.rb', line 362 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.
359 360 361 |
# File 'lib/couchbase/collection_options.rb', line 359 def cas @cas end |
#create_as_deleted ⇒ Boolean
Returns For internal use only: allows creating documents in ‘tombstone’ form.
365 366 367 |
# File 'lib/couchbase/collection_options.rb', line 365 def create_as_deleted @create_as_deleted end |
#durability_level ⇒ :none, ...
Returns level of durability.
368 369 370 |
# File 'lib/couchbase/collection_options.rb', line 368 def durability_level @durability_level end |
#expiry ⇒ Integer
Returns expiration time to associate with the document.
347 348 349 |
# File 'lib/couchbase/collection_options.rb', line 347 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
356 357 358 |
# File 'lib/couchbase/collection_options.rb', line 356 def store_semantics @store_semantics end |
#transcoder ⇒ Object
Returns the value of attribute transcoder.
379 380 381 |
# File 'lib/couchbase/collection_options.rb', line 379 def transcoder @transcoder end |