Class List Method List File List

# Class: Com::Vmware::Appliance::Techpreview::Networking::Ipv4

Inherits:
  VAPI::Bindings::VapiService
  - Object
  - VAPI::Bindings::VapiService
  - Com::Vmware::Appliance::Techpreview::Networking::Ipv4
  show all
Defined in:
  /build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/appliance/techpreview/networking.rb

## Overview

``Com::Vmware::Appliance::Techpreview::Networking::Ipv4`` class provides methods Performs IPV4 network configuration for interfaces.

## Defined Under Namespace

Classes: IPv4Config, IPv4ConfigReadOnly, IPv4Mode

## Instance Method Summary (collapse)

- - (Array<Com::Vmware::Appliance::Techpreview::Networking::Ipv4::IPv4ConfigReadOnly>) get(interfaces)

  Get IPv4 network configuration for interfaces.

- - (Ipv4) initialize(config) constructor

  Constructs a new instance.

- - (Array<Com::Vmware::Appliance::Techpreview::Networking::Ipv4::IPv4ConfigReadOnly>) list

  Get IPv4 network configuration for all configured interfaces.

- - (Void) renew(interfaces)

  Renew IPv4 network configuration on interfaces.

- - (Void) set(config)

  Set IPv4 network configuration.

## Constructor Details

### - (`Ipv4`) initialize(config)

Constructs a new instance.

Parameters:

- config (`VAPI::Bindings::StubConfig`) —

  A hash with the api provider details.

    90
    91
    92
    # File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/appliance/techpreview/networking.rb', line 90

    def initialize(config)
        super(config, @@service_info)
    end

## Instance Method Details

### - (`Array<Com::Vmware::Appliance::Techpreview::Networking::Ipv4::IPv4ConfigReadOnly>`) get(interfaces)

Get IPv4 network configuration for interfaces.

Parameters:

- interfaces (`Array<String>`) —

  Network interfaces to query, for example, “nic0”.

Returns:

- (`Array<Com::Vmware::Appliance::Techpreview::Networking::Ipv4::IPv4ConfigReadOnly>`) —

  IPv4 configuration for each queried interface.

Raises:

- (`Com::Vmware::Vapi::Std::Errors::Error`) —

  Generic error

    142
    143
    144
    145
    146
    # File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/appliance/techpreview/networking.rb', line 142

    def get(interfaces)
        invoke_with_info(@@get_info, {
            'interfaces' => interfaces,
        })
    end

### - (`Array<Com::Vmware::Appliance::Techpreview::Networking::Ipv4::IPv4ConfigReadOnly>`) list

Get IPv4 network configuration for all configured interfaces.

Returns:

- (`Array<Com::Vmware::Appliance::Techpreview::Networking::Ipv4::IPv4ConfigReadOnly>`) —

  IPv4 configuration for each interface.

Raises:

- (`Com::Vmware::Vapi::Std::Errors::Error`) —

  Generic error

    129
    130
    131
    # File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/appliance/techpreview/networking.rb', line 129

    def list()
        invoke_with_info(@@list_info)
    end

### - (`Void`) renew(interfaces)

Renew IPv4 network configuration on interfaces. If the interface is configured to use DHCP for IP address assignment, the lease of the interface is renewed.

Parameters:

- interfaces (`Array<String>`) —

  Interfaces to renew.

Returns:

- (`Void`)

Raises:

- (`Com::Vmware::Vapi::Std::Errors::Error`) —

  Generic error

    102
    103
    104
    105
    106
    # File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/appliance/techpreview/networking.rb', line 102

    def renew(interfaces)
        invoke_with_info(@@renew_info, {
            'interfaces' => interfaces,
        })
    end

### - (`Void`) set(config)

Set IPv4 network configuration.

Parameters:

- config (`Array<Com::Vmware::Appliance::Techpreview::Networking::Ipv4::IPv4Config>`) —

  List of IPv4 configurations.

Returns:

- (`Void`)

Raises:

- (`Com::Vmware::Vapi::Std::Errors::Error`) —

  Generic error

    116
    117
    118
    119
    120
    # File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/appliance/techpreview/networking.rb', line 116

    def set(config)
        invoke_with_info(@@set_info, {
            'config' => config,
        })
    end