Class: Fog::Ecloud::MockDataClasses::Base
- Inherits:
-
Hash
- Object
- Hash
- Fog::Ecloud::MockDataClasses::Base
show all
- Defined in:
- lib/fog/ecloud/mock_data_classes.rb
Direct Known Subclasses
MockBackupInternetService, MockCatalog, MockCatalogItem, MockCatalogItemCustomization, MockCatalogItemVappTemplate, MockData, MockFirewallAcls, MockNetwork, MockNetworkExtensions, MockNetworkIp, MockNetworkIps, MockOrganization, MockPublicIp, MockPublicIpInternetService, MockPublicIpInternetServiceNode, MockPublicIpInternetServiceNodes, MockPublicIpInternetServices, MockPublicIps, MockTaskList, MockVdc, MockVdcInternetServices, MockVersion, MockVirtualMachine, MockVirtualMachineDisk
Class Method Summary
collapse
Instance Method Summary
collapse
Constructor Details
#initialize(data = {}, parent = nil) ⇒ Base
Returns a new instance of Base.
23
24
25
26
27
|
# File 'lib/fog/ecloud/mock_data_classes.rb', line 23
def initialize(data = {}, parent = nil)
@parent = parent
replace(data)
end
|
Class Method Details
.base_url ⇒ Object
11
12
13
|
# File 'lib/fog/ecloud/mock_data_classes.rb', line 11
def self.base_url
@base_url
end
|
.base_url=(url) ⇒ Object
5
6
7
|
# File 'lib/fog/ecloud/mock_data_classes.rb', line 5
def self.base_url=(url)
@base_url = url
end
|
Instance Method Details
#_parent ⇒ Object
29
30
31
|
# File 'lib/fog/ecloud/mock_data_classes.rb', line 29
def _parent
@parent
end
|
#base_url ⇒ Object
33
34
35
|
# File 'lib/fog/ecloud/mock_data_classes.rb', line 33
def base_url
Base.base_url
end
|
#first ⇒ Object
15
16
17
|
# File 'lib/fog/ecloud/mock_data_classes.rb', line 15
def first
raise "Don't do this"
end
|
#href ⇒ Object
37
38
39
|
# File 'lib/fog/ecloud/mock_data_classes.rb', line 37
def href
[base_url, self.class.name.split("::").last, object_id].join("/")
end
|
#inspect ⇒ Object
41
42
43
|
# File 'lib/fog/ecloud/mock_data_classes.rb', line 41
def inspect
"<#{self.class.name} #{object_id} data=#{super}>"
end
|
#last ⇒ Object
19
20
21
|
# File 'lib/fog/ecloud/mock_data_classes.rb', line 19
def last
raise "Don't do this"
end
|