class RightScriptInternal
API 0.1
Public Class Methods
resource_plural_name()
click to toggle source
# File lib/rest_connection/rightscale/right_script_internal.rb, line 43 def self.resource_plural_name "right_scripts" end
resource_singular_name()
click to toggle source
# File lib/rest_connection/rightscale/right_script_internal.rb, line 47 def self.resource_singular_name "right_script" end
Public Instance Methods
attachments()
click to toggle source
# File lib/rest_connection/rightscale/right_script_internal.rb, line 76 def attachments @params["attachments"] ||= fetch_right_script_attachments end
clone()
click to toggle source
clones a RightScript
and returns the new RightScript
resource that’s been created.
# File lib/rest_connection/rightscale/right_script_internal.rb, line 61 def clone t = URI.parse(self.href) RightScript.new(:href => connection.post(t.path + "/clone")) end
commit(message)
click to toggle source
commits a rightscript
# File lib/rest_connection/rightscale/right_script_internal.rb, line 55 def commit(message) t = URI.parse(self.href) RightScript.new(:href => connection.post(t.path + "/commit", :commit_message => message)) end
fetch_right_script_attachments()
click to toggle source
# File lib/rest_connection/rightscale/right_script_internal.rb, line 66 def fetch_right_script_attachments t = URI.parse(self.href) @params["attachments"] = [] connection.get(t.path + "/right_script_attachments").each { |obj| obj.merge!("right_script_href" => self.href) @params["attachments"] << RightScriptAttachmentInternal.new(obj) } @params["attachments"] end
resource_plural_name()
click to toggle source
# File lib/rest_connection/rightscale/right_script_internal.rb, line 35 def resource_plural_name "right_scripts" end
resource_singular_name()
click to toggle source
# File lib/rest_connection/rightscale/right_script_internal.rb, line 39 def resource_singular_name "right_script" end