Class: RMC::Item::SnapshotSet

Inherits:
Object
  • Object
show all
Defined in:
lib/rmc/item/snapshot_set.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(connection, data) ⇒ SnapshotSet

Returns a new instance of SnapshotSet.



19
20
21
22
23
24
25
26
27
28
29
30
31
32
# File 'lib/rmc/item/snapshot_set.rb', line 19

def initialize(connection, data)
  @connection = connection

  @id = data['id']
  @name = data['name']
  @status = data['status']
  @createdAt = data['createdAt']

  @appType = data['appType']
  @recoverySetId = data['recoverySetId']

  @snapExpiry = data['snapExpiry']
  @snapRetention = data['snapRetention']
end

Instance Attribute Details

#appTypeObject (readonly)

Returns the value of attribute appType.



13
14
15
# File 'lib/rmc/item/snapshot_set.rb', line 13

def appType
  @appType
end

#connectionObject

Returns the value of attribute connection.



6
7
8
# File 'lib/rmc/item/snapshot_set.rb', line 6

def connection
  @connection
end

#createdAtObject (readonly)

Returns the value of attribute createdAt.



11
12
13
# File 'lib/rmc/item/snapshot_set.rb', line 11

def createdAt
  @createdAt
end

#idObject (readonly)

Returns the value of attribute id.



8
9
10
# File 'lib/rmc/item/snapshot_set.rb', line 8

def id
  @id
end

#nameObject (readonly)

Returns the value of attribute name.



9
10
11
# File 'lib/rmc/item/snapshot_set.rb', line 9

def name
  @name
end

#recoverySetIdObject (readonly)

Returns the value of attribute recoverySetId.



14
15
16
# File 'lib/rmc/item/snapshot_set.rb', line 14

def recoverySetId
  @recoverySetId
end

#snapExpiryObject (readonly)

Returns the value of attribute snapExpiry.



16
17
18
# File 'lib/rmc/item/snapshot_set.rb', line 16

def snapExpiry
  @snapExpiry
end

#snapRetentionObject (readonly)

Returns the value of attribute snapRetention.



17
18
19
# File 'lib/rmc/item/snapshot_set.rb', line 17

def snapRetention
  @snapRetention
end

#statusObject (readonly)

Returns the value of attribute status.



10
11
12
# File 'lib/rmc/item/snapshot_set.rb', line 10

def status
  @status
end

Instance Method Details

#deleteObject



34
35
36
37
38
39
# File 'lib/rmc/item/snapshot_set.rb', line 34

def delete
  @connection.request(
      :url => "/snapshot-sets/#{@id}",
      :method => :delete,
  )
end