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.
3656 3657 3658 |
# File 'lib/ovirtsdk4/services.rb', line 3656 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.
3690 3691 3692 |
# File 'lib/ovirtsdk4/services.rb', line 3690 def list(opts = {}) internal_get(LIST, opts) end |
#profile_service(id) ⇒ AssignedVnicProfileService
Locates the profile
service.
3701 3702 3703 |
# File 'lib/ovirtsdk4/services.rb', line 3701 def profile_service(id) AssignedVnicProfileService.new(self, id) end |
#service(path) ⇒ Service
Locates the service corresponding to the given path.
3712 3713 3714 3715 3716 3717 3718 3719 3720 3721 |
# File 'lib/ovirtsdk4/services.rb', line 3712 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 |