Class: OsTemplate

Inherits:
Object
  • Object
show all
Defined in:
lib/secured_cloud_api_client/os_template.rb

Overview

OS Templates for creating new virtual machines.

@author

Alan Vella

Instance Method Summary collapse

Constructor Details

#initialize(name, version, minimumStorageSpace, defaultAdministratorUsername, diskExpandable) ⇒ OsTemplate

Returns a new instance of OsTemplate.



11
12
13
14
15
16
17
# File 'lib/secured_cloud_api_client/os_template.rb', line 11

def initialize(name, version, minimumStorageSpace, defaultAdministratorUsername, diskExpandable)
  @name = name
  @version = version
  @minimumStorageSpace = minimumStorageSpace
  @defaultAdministratorUsername = defaultAdministratorUsername
  @diskExpandable = diskExpandable
end

Instance Method Details

#get_administrator_usernameObject



42
43
44
# File 'lib/secured_cloud_api_client/os_template.rb', line 42

def get_administrator_username
  return @defaultAdministratorUsername
end

#get_detailsObject



20
21
22
23
24
25
26
27
# File 'lib/secured_cloud_api_client/os_template.rb', line 20

def get_details()
  details =  "Name                       : #{@name}\n"
  details += "Version                    : #{@version}\n"
  details += "Minimum Storage Space in Gb: #{@minimumStorageSpace}\n"
  details += "Default Admin Username     : #{@defaultAdministratorUsername}\n"
  details += "Disk Expandable            : #{@diskExpandable}\n"
  return details
end

#get_disk_expandableObject



46
47
48
# File 'lib/secured_cloud_api_client/os_template.rb', line 46

def get_disk_expandable
  return @diskExpandable
end

#get_minimum_storage_spaceObject



38
39
40
# File 'lib/secured_cloud_api_client/os_template.rb', line 38

def get_minimum_storage_space
  return @minimumStorageSpace
end

#get_nameObject



30
31
32
# File 'lib/secured_cloud_api_client/os_template.rb', line 30

def get_name
  return @name
end

#get_versionObject



34
35
36
# File 'lib/secured_cloud_api_client/os_template.rb', line 34

def get_version
  return @version
end