class Crowbar::Client::Command::Interface::Enable
Implementation for the interface enable command
Public Instance Methods
execute()
click to toggle source
# File lib/crowbar/client/command/interface/enable.rb, line 31 def execute request.process do |request| case request.code when 200 say JSON.pretty_generate( content_from(request) ) else err request.parsed_response["error"] end end end
request()
click to toggle source
# File lib/crowbar/client/command/interface/enable.rb, line 25 def request @request ||= Request::Interface::Enable.new( args ) end
Protected Instance Methods
content_from(request)
click to toggle source
# File lib/crowbar/client/command/interface/enable.rb, line 46 def content_from(request) request.parsed_response end