class NLBSG::Client
Constants
- DEFAULT_CONFIG
Public Instance Methods
get_availability_info(options)
click to toggle source
# File lib/nlbsg/client.rb, line 23 def get_availability_info(options) request = GetAvailabilityInfoRequest.new(options).build response = client.call(:get_availability_info, message: request) GetAvailabilityInfoResponse.new(response) end
Also aliased as: availability
get_title_details(options)
click to toggle source
# File lib/nlbsg/client.rb, line 17 def get_title_details(options) request = GetTitleDetailsRequest.new(options).build response = client.call(:get_title_details, message: request) GetTitleDetailsResponse.new(response) end
Also aliased as: title
operations()
click to toggle source
# File lib/nlbsg/client.rb, line 29 def operations client.operations end
search(options)
click to toggle source
# File lib/nlbsg/client.rb, line 11 def search(options) request = SearchRequest.new(options).build response = client.call(:search, message: request) SearchResponse.new(response) end
Private Instance Methods
client()
click to toggle source
# File lib/nlbsg/client.rb, line 38 def client @client ||= Savon.client(config) end
config()
click to toggle source
# File lib/nlbsg/client.rb, line 42 def config DEFAULT_CONFIG.merge(wsdl: wsdl) end
wsdl()
click to toggle source
# File lib/nlbsg/client.rb, line 46 def wsdl if NLBSG.env == :production NLBSG::WSDL[:production] elsif NLBSG.env == :staging NLBSG::WSDL[:staging] end end