class ArXiv::ComposedQuery
Public Class Methods
new(str, *args)
click to toggle source
# File lib/ar_xiv/request.rb, line 50 def initialize(str, *args) case str when String @op = str @requests = args when Query @op = "" @request = str else raise "Fail to make a Composed Request" end end
Public Instance Methods
to_query_string()
click to toggle source
# File lib/ar_xiv/request.rb, line 63 def to_query_string if @op.empty? @request.to_query_string else "%28#{@requests.map(&:to_query_string).join("%29+#{@op.upcase}+%28")}%29" end end