Class: FedoraMigrate::RubydoraConnection
- Inherits:
-
Object
- Object
- FedoraMigrate::RubydoraConnection
- Defined in:
- lib/fedora_migrate/rubydora_connection.rb
Instance Attribute Summary collapse
-
#connection ⇒ Object
Returns the value of attribute connection.
-
#options ⇒ Object
Returns the value of attribute options.
Instance Method Summary collapse
- #connect(force = false) ⇒ Object
-
#initialize(params = {}) ⇒ RubydoraConnection
constructor
A new instance of RubydoraConnection.
Constructor Details
#initialize(params = {}) ⇒ RubydoraConnection
Returns a new instance of RubydoraConnection.
6 7 8 9 10 |
# File 'lib/fedora_migrate/rubydora_connection.rb', line 6 def initialize(params={}) params = params.dup self. = params connect end |
Instance Attribute Details
#connection ⇒ Object
Returns the value of attribute connection.
4 5 6 |
# File 'lib/fedora_migrate/rubydora_connection.rb', line 4 def connection @connection end |
#options ⇒ Object
Returns the value of attribute options.
4 5 6 |
# File 'lib/fedora_migrate/rubydora_connection.rb', line 4 def @options end |
Instance Method Details
#connect(force = false) ⇒ Object
12 13 14 15 16 17 |
# File 'lib/fedora_migrate/rubydora_connection.rb', line 12 def connect(force=false) return unless @connection.nil? or force = [:url, :user, :password, :timeout, :open_timeout, :ssl_client_cert, :ssl_client_key, :validateChecksum] = .reject { |k,v| not .include?(k) } @connection = Rubydora.connect end |