Class: Com::Vmware::Cis::Tagging::CategoryModel::Cardinality
- Inherits:
-
VAPI::Bindings::VapiEnum
- Object
- VAPI::Bindings::VapiEnum
- Com::Vmware::Cis::Tagging::CategoryModel::Cardinality
- Defined in:
- /build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/cis/tagging.rb
Overview
The ``Com::Vmware::Cis::Tagging::CategoryModel::Cardinality`` enumerated type defines the number of tags in a category that can be assigned to an object.
Constant Summary
- SINGLE =
Cardinality.new('SINGLE')
- MULTIPLE =
Cardinality.new('MULTIPLE')
Instance Attribute Summary (collapse)
-
- (Com::Vmware::Cis::Tagging::CategoryModel::Cardinality) multiple
An object can be assigned several of the tags in this category.
-
- (Com::Vmware::Cis::Tagging::CategoryModel::Cardinality) single
An object can only be assigned one of the tags in this category.
Class Method Summary (collapse)
-
+ (VAPI::Bindings::EnumType) binding_type
Holds (gets or creates) the binding type metadata for this enumeration type.
-
+ (Cardinality) from_string(value)
Converts from a string value (perhaps off the wire) to an instance of this enum type.
Instance Attribute Details
- (Com::Vmware::Cis::Tagging::CategoryModel::Cardinality) multiple
An object can be assigned several of the tags in this category. For example, if a category is “Server”, then different tags of this category would be “AppServer”, “DatabaseServer” and so on. In this case a VM object can be assigned more than one of the above tags and hence the cardinality of the associated category here is multiple.
1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 |
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/cis/tagging.rb', line 1390 class Cardinality < 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.cis.tagging.category_model.cardinality', Cardinality) 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 [Cardinality] 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 Cardinality.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] single # @return [Com::Vmware::Cis::Tagging::CategoryModel::Cardinality] # An object can only be assigned one of the tags in this category. For example, if a category is "Operating System", then different tags of this category would be "Windows", "Linux", and so on. In this case a VM object can be assigned only one of these tags and hence the cardinality of the associated category here is single. SINGLE = Cardinality.new('SINGLE') # @!attribute [rw] multiple # @return [Com::Vmware::Cis::Tagging::CategoryModel::Cardinality] # An object can be assigned several of the tags in this category. For example, if a category is "Server", then different tags of this category would be "AppServer", "DatabaseServer" and so on. In this case a VM object can be assigned more than one of the above tags and hence the cardinality of the associated category here is multiple. MULTIPLE = Cardinality.new('MULTIPLE') end |
- (Com::Vmware::Cis::Tagging::CategoryModel::Cardinality) single
An object can only be assigned one of the tags in this category. For example, if a category is “Operating System”, then different tags of this category would be “Windows”, “Linux”, and so on. In this case a VM object can be assigned only one of these tags and hence the cardinality of the associated category here is single.
1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 |
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/cis/tagging.rb', line 1390 class Cardinality < 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.cis.tagging.category_model.cardinality', Cardinality) 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 [Cardinality] 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 Cardinality.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] single # @return [Com::Vmware::Cis::Tagging::CategoryModel::Cardinality] # An object can only be assigned one of the tags in this category. For example, if a category is "Operating System", then different tags of this category would be "Windows", "Linux", and so on. In this case a VM object can be assigned only one of these tags and hence the cardinality of the associated category here is single. SINGLE = Cardinality.new('SINGLE') # @!attribute [rw] multiple # @return [Com::Vmware::Cis::Tagging::CategoryModel::Cardinality] # An object can be assigned several of the tags in this category. For example, if a category is "Server", then different tags of this category would be "AppServer", "DatabaseServer" and so on. In this case a VM object can be assigned more than one of the above tags and hence the cardinality of the associated category here is multiple. MULTIPLE = Cardinality.new('MULTIPLE') end |
Class Method Details
+ (VAPI::Bindings::EnumType) binding_type
Holds (gets or creates) the binding type metadata for this enumeration type.
1396 1397 1398 1399 1400 |
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/cis/tagging.rb', line 1396 def binding_type @binding_type ||= VAPI::Bindings::EnumType.new( 'com.vmware.cis.tagging.category_model.cardinality', Cardinality) end |
+ (Cardinality) from_string(value)
Converts from a string value (perhaps off the wire) to an instance of this enum type.
1407 1408 1409 1410 1411 1412 1413 |
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/cis/tagging.rb', line 1407 def from_string(value) begin const_get(value) rescue NameError Cardinality.new('UNKNOWN', value) end end |