Class: Com::Vmware::Vcenter::Ovf::IpAllocationParams::IpProtocol

Inherits:
VAPI::Bindings::VapiEnum
  • Object
show all
Defined in:
/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/vcenter/ovf.rb

Overview

The ``Com::Vmware::Vcenter::Ovf::IpAllocationParams::IpProtocol`` enumerated type defines the IP protocols supported by the guest software.

Constant Summary

IP_V4 =
IpProtocol.new('IP_V4')
IP_V6 =
IpProtocol.new('IP_V6')

Instance Attribute Summary (collapse)

Class Method Summary (collapse)

Instance Attribute Details

- (Com::Vmware::Vcenter::Ovf::IpAllocationParams::IpProtocol) ip_v4

It supports the IPv4 protocol.



1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/vcenter/ovf.rb', line 1497

class IpProtocol < VAPI::Bindings::VapiEnum

    class << self
        # Holds (gets or creates) the binding type metadata for this enumeration type.
        # @scope class
        # @return [VAPI::Bindings::EnumType] the binding type
        def binding_type
            @binding_type ||= VAPI::Bindings::EnumType.new(
                'com.vmware.vcenter.ovf.ip_allocation_params.ip_protocol',
                IpProtocol)
        end

        # Converts from a string value (perhaps off the wire) to an instance
        # of this enum type.
        # @param value [String] the actual value of the enum instance
        # @return [IpProtocol] the instance found for the value, otherwise
        #         an unknown instance will be built for the value
        def from_string(value)
            begin
                const_get(value)
            rescue NameError
                IpProtocol.new('UNKNOWN', value)
            end
        end
    end

    private

    # Constructs a new instance.
    # @param value [String] the actual value of the enum instance
    # @param unknown [String] the unknown value when value is 'UKNOWN'
    def initialize(value, unknown=nil)
        super(self.class.binding_type, value, unknown)
    end

    public

    # @!attribute [rw] ip_v4
    #     @return [Com::Vmware::Vcenter::Ovf::IpAllocationParams::IpProtocol]
    #     It supports the IPv4 protocol.
    IP_V4 = IpProtocol.new('IP_V4')

    # @!attribute [rw] ip_v6
    #     @return [Com::Vmware::Vcenter::Ovf::IpAllocationParams::IpProtocol]
    #     It supports the IPv6 protocol.
    IP_V6 = IpProtocol.new('IP_V6')

end

- (Com::Vmware::Vcenter::Ovf::IpAllocationParams::IpProtocol) ip_v6

It supports the IPv6 protocol.



1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/vcenter/ovf.rb', line 1497

class IpProtocol < VAPI::Bindings::VapiEnum

    class << self
        # Holds (gets or creates) the binding type metadata for this enumeration type.
        # @scope class
        # @return [VAPI::Bindings::EnumType] the binding type
        def binding_type
            @binding_type ||= VAPI::Bindings::EnumType.new(
                'com.vmware.vcenter.ovf.ip_allocation_params.ip_protocol',
                IpProtocol)
        end

        # Converts from a string value (perhaps off the wire) to an instance
        # of this enum type.
        # @param value [String] the actual value of the enum instance
        # @return [IpProtocol] the instance found for the value, otherwise
        #         an unknown instance will be built for the value
        def from_string(value)
            begin
                const_get(value)
            rescue NameError
                IpProtocol.new('UNKNOWN', value)
            end
        end
    end

    private

    # Constructs a new instance.
    # @param value [String] the actual value of the enum instance
    # @param unknown [String] the unknown value when value is 'UKNOWN'
    def initialize(value, unknown=nil)
        super(self.class.binding_type, value, unknown)
    end

    public

    # @!attribute [rw] ip_v4
    #     @return [Com::Vmware::Vcenter::Ovf::IpAllocationParams::IpProtocol]
    #     It supports the IPv4 protocol.
    IP_V4 = IpProtocol.new('IP_V4')

    # @!attribute [rw] ip_v6
    #     @return [Com::Vmware::Vcenter::Ovf::IpAllocationParams::IpProtocol]
    #     It supports the IPv6 protocol.
    IP_V6 = IpProtocol.new('IP_V6')

end

Class Method Details

+ (VAPI::Bindings::EnumType) binding_type

Holds (gets or creates) the binding type metadata for this enumeration type.

Returns:

  • (VAPI::Bindings::EnumType)

    the binding type



1503
1504
1505
1506
1507
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/vcenter/ovf.rb', line 1503

def binding_type
    @binding_type ||= VAPI::Bindings::EnumType.new(
        'com.vmware.vcenter.ovf.ip_allocation_params.ip_protocol',
        IpProtocol)
end

+ (IpProtocol) from_string(value)

Converts from a string value (perhaps off the wire) to an instance of this enum type.

Parameters:

  • value (String)

    the actual value of the enum instance

Returns:

  • (IpProtocol)

    the instance found for the value, otherwise an unknown instance will be built for the value



1514
1515
1516
1517
1518
1519
1520
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/vcenter/ovf.rb', line 1514

def from_string(value)
    begin
        const_get(value)
    rescue NameError
        IpProtocol.new('UNKNOWN', value)
    end
end