Method: UWDC::XML#http_xml
- Defined in:
- lib/uwdc/xml.rb
#http_xml(xml, status) ⇒ Object
14 15 16 17 18 19 20 21 22 23 24 25 26 27 |
# File 'lib/uwdc/xml.rb', line 14 def http_xml(xml,status) unless xml begin # http://depot.library.wisc.edu:9090/fedora/objects/1711.dl:33QOBSVPJLWEM8S/methods/1711.dl:SDefineFirstClassObject/viewMets #response = http_client.get("http://depot.library.wisc.edu/uwdcutils/METS/1711.dl:#{@id}") response = http_client.get("http://depot.library.wisc.edu:9090/fedora/objects/1711.dl:#{@id}/methods/1711.dl:SDefineFirstClassObject/viewMets") xml = response.body status = response.status rescue TimeoutError, HTTPClient::ConfigurationError, HTTPClient::BadResponseError, Nokogiri::SyntaxError => error exception = error end end [xml,status] end |