module Ethon::Easies::Http::Actionable
def form
def form @form ||= Form.new(options[:body]) end
def initialize(url, options)
-
(Action)- A new action.
Parameters:
-
options(Hash) -- The options. -
url(String) -- The url.
Other tags:
- Example: Create a new action. -
def initialize(url, options) @url = url @options = options end
def options
def options @options end
def params
def params @params ||= Params.new(options[:params]) end
def set_customs(easy)
-
easy(Easy) -- The easy to setup.
Other tags:
- Example: Setup custom things. -
def set_customs(easy) end
def set_form(easy)
-
easy(Easy) -- The easy to setup.
Other tags:
- Example: Setup nothing. -
def set_form(easy) end
def set_nothing(easy)
-
easy(Easy) -- The easy to setup.
Other tags:
- Example: Setup nothing. -
def set_nothing(easy) easy.url = url end
def set_params(easy)
-
easy(Easy) -- The easy to setup.
Other tags:
- Example: Setup nothing. -
def set_params(easy) params.escape = true easy.url = "#{url}?#{params.to_s}" end
def setup(easy)
-
easy(easy) -- the easy to setup.
Other tags:
- Example: setup. -
def setup(easy) set_nothing(easy) if params.empty? && form.empty? set_params(easy) unless params.empty? set_form(easy) unless form.empty? set_customs(easy) easy.set_attributes(options) end
def url
def url @url end