Class: Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType

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

Overview

The ``Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType`` enumerated type provides enumeration values for each of the generic types provided by the infrastructure.

Constant Summary

LIST =
GenericType.new('LIST')
MAP =
GenericType.new('MAP')
OPTIONAL =
GenericType.new('OPTIONAL')
SET =
GenericType.new('SET')

Instance Attribute Summary (collapse)

Class Method Summary (collapse)

Instance Attribute Details

- (Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType) list

Indicates the generic type is a list.



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
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/vapi/metadata/metamodel.rb', line 1504

class GenericType < 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.vapi.metadata.metamodel.generic_instantiation.generic_type',
                GenericType)
        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 [GenericType] 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
                GenericType.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] list
    #     @return [Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType]
    #     Indicates the generic type is a list.
    LIST = GenericType.new('LIST')

    # @!attribute [rw] map
    #     @return [Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType]
    #     Indicates the generic type is a map.
    MAP = GenericType.new('MAP')

    # @!attribute [rw] optional
    #     @return [Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType]
    #     Indicates the generic type is an optional.
    OPTIONAL = GenericType.new('OPTIONAL')

    # @!attribute [rw] set
    #     @return [Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType]
    #     Indicates the generic type is a set.
    SET = GenericType.new('SET')

end

- (Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType) map

Indicates the generic type is a map.



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
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/vapi/metadata/metamodel.rb', line 1504

class GenericType < 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.vapi.metadata.metamodel.generic_instantiation.generic_type',
                GenericType)
        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 [GenericType] 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
                GenericType.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] list
    #     @return [Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType]
    #     Indicates the generic type is a list.
    LIST = GenericType.new('LIST')

    # @!attribute [rw] map
    #     @return [Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType]
    #     Indicates the generic type is a map.
    MAP = GenericType.new('MAP')

    # @!attribute [rw] optional
    #     @return [Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType]
    #     Indicates the generic type is an optional.
    OPTIONAL = GenericType.new('OPTIONAL')

    # @!attribute [rw] set
    #     @return [Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType]
    #     Indicates the generic type is a set.
    SET = GenericType.new('SET')

end

- (Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType) optional

Indicates the generic type is an optional.



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
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/vapi/metadata/metamodel.rb', line 1504

class GenericType < 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.vapi.metadata.metamodel.generic_instantiation.generic_type',
                GenericType)
        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 [GenericType] 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
                GenericType.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] list
    #     @return [Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType]
    #     Indicates the generic type is a list.
    LIST = GenericType.new('LIST')

    # @!attribute [rw] map
    #     @return [Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType]
    #     Indicates the generic type is a map.
    MAP = GenericType.new('MAP')

    # @!attribute [rw] optional
    #     @return [Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType]
    #     Indicates the generic type is an optional.
    OPTIONAL = GenericType.new('OPTIONAL')

    # @!attribute [rw] set
    #     @return [Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType]
    #     Indicates the generic type is a set.
    SET = GenericType.new('SET')

end

- (Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType) set

Indicates the generic type is a set.



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
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/vapi/metadata/metamodel.rb', line 1504

class GenericType < 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.vapi.metadata.metamodel.generic_instantiation.generic_type',
                GenericType)
        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 [GenericType] 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
                GenericType.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] list
    #     @return [Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType]
    #     Indicates the generic type is a list.
    LIST = GenericType.new('LIST')

    # @!attribute [rw] map
    #     @return [Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType]
    #     Indicates the generic type is a map.
    MAP = GenericType.new('MAP')

    # @!attribute [rw] optional
    #     @return [Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType]
    #     Indicates the generic type is an optional.
    OPTIONAL = GenericType.new('OPTIONAL')

    # @!attribute [rw] set
    #     @return [Com::Vmware::Vapi::Metadata::Metamodel::GenericInstantiation::GenericType]
    #     Indicates the generic type is a set.
    SET = GenericType.new('SET')

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



1510
1511
1512
1513
1514
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/vapi/metadata/metamodel.rb', line 1510

def binding_type
    @binding_type ||= VAPI::Bindings::EnumType.new(
        'com.vmware.vapi.metadata.metamodel.generic_instantiation.generic_type',
        GenericType)
end

+ (GenericType) 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:

  • (GenericType)

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



1521
1522
1523
1524
1525
1526
1527
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/vapi/metadata/metamodel.rb', line 1521

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