Class: TcServer::Revisions

Inherits:
Shared::MutableCollection show all
Defined in:
lib/vas/tc_server/revisions.rb

Overview

Used to enumerate, create, and delete application revisions.

Instance Attribute Summary

Attributes inherited from Shared::Resource

#location, #security

Instance Method Summary collapse

Methods inherited from Shared::MutableCollection

#delete

Methods inherited from Shared::Collection

#each

Constructor Details

#initialize(location, client) ⇒ Revisions

:nodoc:



23
24
25
# File 'lib/vas/tc_server/revisions.rb', line 23

def initialize(location, client) #:nodoc:
  super(location, client, "revisions", Revision)
end

Instance Method Details

#create(revision_image) ⇒ Object

Creates a Revision by deploying the RevisionImage revision_image



28
29
30
# File 'lib/vas/tc_server/revisions.rb', line 28

def create(revision_image)
  Revision.new(client.post(location, { :image => revision_image.location}, 'group-revision'), client)
end