== qresource
qresource is very much a work-in-progress. as of 0.0.3 it only supports GET’s
sample usage:
code
class Qsample < Qresource::Base
attr_accessor :test
end
@sample_client = Qsample.new :api_url => ‘http://gottfolk.se/qresource’
@samples = @sample_client.all
@first_sample = @sample_client.get(1)
@first_sample.test
# => “sample string”
Base uses Hash.from_xml which can be quite… not so fast. but just override
the from_xml method, it takes one argument which is the libxml node.