Class: Com::Vmware::Appliance::Techpreview::Localaccounts::User::UserRole

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

Overview

``Com::Vmware::Appliance::Techpreview::Localaccounts::User::UserRole`` enumerated type Defines user roles for appliance

Constant Summary

ADMIN =
UserRole.new('ADMIN')
OPERATOR =
UserRole.new('OPERATOR')
SUPER_ADMIN =
UserRole.new('SUPER_ADMIN')

Instance Attribute Summary (collapse)

Class Method Summary (collapse)

Instance Attribute Details

- (Com::Vmware::Appliance::Techpreview::Localaccounts::User::UserRole) admin

Able to configure the appliance.



477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/appliance/techpreview/localaccounts.rb', line 477

class UserRole < 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.appliance.techpreview.localaccounts.user.user_role',
                UserRole)
        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 [UserRole] 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
                UserRole.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] admin
    #     @return [Com::Vmware::Appliance::Techpreview::Localaccounts::User::UserRole]
    #     Able to configure the appliance.
    ADMIN = UserRole.new('ADMIN')

    # @!attribute [rw] operator
    #     @return [Com::Vmware::Appliance::Techpreview::Localaccounts::User::UserRole]
    #     Able to read the appliance configuration.
    OPERATOR = UserRole.new('OPERATOR')

    # @!attribute [rw] super_admin
    #     @return [Com::Vmware::Appliance::Techpreview::Localaccounts::User::UserRole]
    #     Able to configure the appliance, manage local accounts and use the BASH shell
    SUPER_ADMIN = UserRole.new('SUPER_ADMIN')

end

- (Com::Vmware::Appliance::Techpreview::Localaccounts::User::UserRole) operator

Able to read the appliance configuration.



477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/appliance/techpreview/localaccounts.rb', line 477

class UserRole < 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.appliance.techpreview.localaccounts.user.user_role',
                UserRole)
        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 [UserRole] 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
                UserRole.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] admin
    #     @return [Com::Vmware::Appliance::Techpreview::Localaccounts::User::UserRole]
    #     Able to configure the appliance.
    ADMIN = UserRole.new('ADMIN')

    # @!attribute [rw] operator
    #     @return [Com::Vmware::Appliance::Techpreview::Localaccounts::User::UserRole]
    #     Able to read the appliance configuration.
    OPERATOR = UserRole.new('OPERATOR')

    # @!attribute [rw] super_admin
    #     @return [Com::Vmware::Appliance::Techpreview::Localaccounts::User::UserRole]
    #     Able to configure the appliance, manage local accounts and use the BASH shell
    SUPER_ADMIN = UserRole.new('SUPER_ADMIN')

end

- (Com::Vmware::Appliance::Techpreview::Localaccounts::User::UserRole) super_admin

Able to configure the appliance, manage local accounts and use the BASH shell



477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/appliance/techpreview/localaccounts.rb', line 477

class UserRole < 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.appliance.techpreview.localaccounts.user.user_role',
                UserRole)
        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 [UserRole] 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
                UserRole.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] admin
    #     @return [Com::Vmware::Appliance::Techpreview::Localaccounts::User::UserRole]
    #     Able to configure the appliance.
    ADMIN = UserRole.new('ADMIN')

    # @!attribute [rw] operator
    #     @return [Com::Vmware::Appliance::Techpreview::Localaccounts::User::UserRole]
    #     Able to read the appliance configuration.
    OPERATOR = UserRole.new('OPERATOR')

    # @!attribute [rw] super_admin
    #     @return [Com::Vmware::Appliance::Techpreview::Localaccounts::User::UserRole]
    #     Able to configure the appliance, manage local accounts and use the BASH shell
    SUPER_ADMIN = UserRole.new('SUPER_ADMIN')

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



483
484
485
486
487
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/appliance/techpreview/localaccounts.rb', line 483

def binding_type
    @binding_type ||= VAPI::Bindings::EnumType.new(
        'com.vmware.appliance.techpreview.localaccounts.user.user_role',
        UserRole)
end

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

  • (UserRole)

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



494
495
496
497
498
499
500
# File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/appliance/techpreview/localaccounts.rb', line 494

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