Class: Couchbase::Options::Cluster
- Inherits:
-
Object
- Object
- Couchbase::Options::Cluster
- Defined in:
- lib/couchbase/options.rb,
/Users/sergey.auseyau/code/couchbase-ruby-client/lib/couchbase/options.rb more...
Overview
Options for Cluster.connect
Instance Attribute Summary collapse
Instance Method Summary collapse
- #authenticate(username, password) ⇒ Object
-
#initialize(authenticator: nil) {|self| ... } ⇒ Cluster
constructor
Creates an instance of options for Cluster.connect.
Constructor Details
#initialize(authenticator: nil) {|self| ... } ⇒ Cluster
Creates an instance of options for Cluster.connect
1103 1104 1105 1106 |
# File 'lib/couchbase/options.rb', line 1103 def initialize(authenticator: nil) @authenticator = authenticator yield self if block_given? end |
Instance Attribute Details
#authenticator ⇒ PasswordAuthenticator, CertificateAuthenticator
1096 1097 1098 |
# File 'lib/couchbase/options.rb', line 1096 def authenticator @authenticator end |
Instance Method Details
#authenticate(username, password) ⇒ Object
1110 1111 1112 |
# File 'lib/couchbase/options.rb', line 1110 def authenticate(username, password) @authenticator = PasswordAuthenticator.new(username, password) end |