Class: Couchbase::Options::UpsertMulti
- Inherits:
-
Base
- Object
- Base
- Couchbase::Options::UpsertMulti
show all
- Defined in:
- lib/couchbase/options.rb,
/Users/sergey.auseyau/code/couchbase-ruby-client/lib/couchbase/options.rb more...
Overview
Instance Attribute Summary collapse
Attributes inherited from Base
#client_context, #parent_span, #retry_strategy, #timeout
Instance Method Summary
collapse
Constructor Details
#initialize(expiry: nil, transcoder: JsonTranscoder.new, durability_level: :none, timeout: nil, retry_strategy: nil, client_context: nil, parent_span: nil) {|| ... } ⇒ UpsertMulti
[View source]
588
589
590
591
592
593
594
595
596
597
598
599
600
|
# File 'lib/couchbase/options.rb', line 588
def initialize(expiry: nil,
transcoder: JsonTranscoder.new,
durability_level: :none,
timeout: nil,
retry_strategy: nil,
client_context: nil,
parent_span: nil)
super(timeout: timeout, retry_strategy: retry_strategy, client_context: client_context, parent_span: parent_span)
@expiry = Utils::Time.(expiry)
@transcoder = transcoder
@durability_level = durability_level
yield self if block_given?
end
|
Instance Attribute Details
#durability_level ⇒ Symbol
562
563
564
|
# File 'lib/couchbase/options.rb', line 562
def durability_level
@durability_level
end
|
#expiry ⇒ Integer, ...
560
561
562
|
# File 'lib/couchbase/options.rb', line 560
def expiry
@expiry
end
|
#transcoder ⇒ JsonTranscoder, #encode(Object)
561
562
563
|
# File 'lib/couchbase/options.rb', line 561
def transcoder
@transcoder
end
|
Instance Method Details
#to_backend ⇒ Object
[View source]
602
603
604
605
606
607
608
|
# File 'lib/couchbase/options.rb', line 602
def to_backend
{
timeout: @timeout.respond_to?(:in_milliseconds) ? @timeout.public_send(:in_milliseconds) : @timeout,
expiry: @expiry,
durability_level: @durability_level,
}
end
|