Class: OvirtSDK4::AssignedVnicProfilesService
- Defined in:
- lib/ovirtsdk4/services.rb,
lib/ovirtsdk4/services.rb
Instance Method Summary collapse
-
#add(profile, opts = {}) ⇒ VnicProfile
Add a new virtual network interface card profile for the network.
-
#list(opts = {}) ⇒ Array<VnicProfile>
Returns the list of VNIC profiles assifned to the network.
-
#profile_service(id) ⇒ AssignedVnicProfileService
Locates the
profile
service. -
#service(path) ⇒ Service
Locates the service corresponding to the given path.
Methods inherited from Service
Instance Method Details
#add(profile, opts = {}) ⇒ VnicProfile
Add a new virtual network interface card profile for the network.
3095 3096 3097 |
# File 'lib/ovirtsdk4/services.rb', line 3095 def add(profile, opts = {}) internal_add(profile, VnicProfile, ADD, opts) end |
#list(opts = {}) ⇒ Array<VnicProfile>
Returns the list of VNIC profiles assifned to the network.
The order of the returned VNIC profiles isn’t guaranteed.
3129 3130 3131 |
# File 'lib/ovirtsdk4/services.rb', line 3129 def list(opts = {}) internal_get(LIST, opts) end |
#profile_service(id) ⇒ AssignedVnicProfileService
Locates the profile
service.
3140 3141 3142 |
# File 'lib/ovirtsdk4/services.rb', line 3140 def profile_service(id) AssignedVnicProfileService.new(self, id) end |
#service(path) ⇒ Service
Locates the service corresponding to the given path.
3151 3152 3153 3154 3155 3156 3157 3158 3159 3160 |
# File 'lib/ovirtsdk4/services.rb', line 3151 def service(path) if path.nil? || path == '' return self end index = path.index('/') if index.nil? return profile_service(path) end return profile_service(path[0..(index - 1)]).service(path[(index +1)..-1]) end |