Class: Skala::AlephAdapter
- Defined in:
- lib/skala/aleph_adapter.rb
Defined Under Namespace
Modules: ResolveUser Classes: AuthenticateUser, CreateUserHoldRequest, DeleteUserHoldRequest, GetRecord, GetRecordHoldableItems, GetRecordItems, GetUser, GetUserFormerLoans, GetUserHoldRequests, GetUserInterLibraryLoans, GetUserLoans, GetUserTransactions, RenewUserLoan, RenewUserLoans, UpdateUser
Instance Attribute Summary collapse
-
#default_document_base ⇒ Object
Returns the value of attribute default_document_base.
-
#default_user_library ⇒ Object
Returns the value of attribute default_user_library.
-
#restful_api_url ⇒ Object
Returns the value of attribute restful_api_url.
-
#x_services_url ⇒ Object
Returns the value of attribute x_services_url.
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ AlephAdapter
constructor
A new instance of AlephAdapter.
-
#restful_api ⇒ Object
apis used to implemented the operations.
- #x_services ⇒ Object
Methods inherited from Adapter
#authenticate_user, #create_user_hold_request, #delete_user_hold_request, #get_record_holdable_items, #get_record_items, #get_records, #get_user, #get_user_cash, #get_user_former_loans, #get_user_hold_requests, #get_user_inter_library_loans, #get_user_loans, #get_user_transactions, #renew_user_loan, #renew_user_loans, #search, #update_user
Constructor Details
#initialize(options = {}) ⇒ AlephAdapter
Returns a new instance of AlephAdapter.
28 29 30 31 32 33 34 35 |
# File 'lib/skala/aleph_adapter.rb', line 28 def initialize( = {}) HashWithIndifferentAccess.new().try do || self.default_document_base = [:default_document_base] self.default_user_library = [:default_user_library] self.restful_api_url = [:restful_api_url] self.x_services_url = [:x_services_url] end end |
Instance Attribute Details
#default_document_base ⇒ Object
Returns the value of attribute default_document_base.
23 24 25 |
# File 'lib/skala/aleph_adapter.rb', line 23 def default_document_base @default_document_base end |
#default_user_library ⇒ Object
Returns the value of attribute default_user_library.
24 25 26 |
# File 'lib/skala/aleph_adapter.rb', line 24 def default_user_library @default_user_library end |
#restful_api_url ⇒ Object
Returns the value of attribute restful_api_url.
25 26 27 |
# File 'lib/skala/aleph_adapter.rb', line 25 def restful_api_url @restful_api_url end |
#x_services_url ⇒ Object
Returns the value of attribute x_services_url.
26 27 28 |
# File 'lib/skala/aleph_adapter.rb', line 26 def x_services_url @x_services_url end |
Instance Method Details
#restful_api ⇒ Object
apis used to implemented the operations
40 41 42 |
# File 'lib/skala/aleph_adapter.rb', line 40 def restful_api @restful_api ||= AlephApi::RestfulApiClient.new(url: @restful_api_url) end |
#x_services ⇒ Object
44 45 46 |
# File 'lib/skala/aleph_adapter.rb', line 44 def x_services @x_services ||= AlephApi::XServicesClient.new(url: @x_services_url) end |