Class List Method List File List

# Class: Com::Vmware::Vapi::Metadata::Privilege::Service::Operation

Inherits:
  VAPI::Bindings::VapiService
  - Object
  - VAPI::Bindings::VapiService
  - Com::Vmware::Vapi::Metadata::Privilege::Service::Operation
  show all
Defined in:
  /build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/vapi/metadata/privilege/service.rb

## Overview

The ``Com::Vmware::Vapi::Metadata::Privilege::Service::Operation`` class provides methods to retrieve privilege information of an operation element.

     An operation element is said to contain privilege information if there are any privileges assigned to the operation element or if one of the parameter elements contained in it has privileges assigned in privilege definition file.

## Constant Summary

RESOURCE_TYPE =

      'com.vmware.vapi.operation'

## Instance Method Summary (collapse)

- - (Com::Vmware::Vapi::Metadata::Privilege::OperationInfo) get(service_id, operation_id)

  Retrieves the privilege information about an operation element corresponding to ``operation_id`` contained in the service element corresponding to ``service_id`` .

- - (Operation) initialize(config) constructor

  Constructs a new instance.

- - (Array<String>) list(service_id)

  Returns the identifiers for the operation elements contained in the service element corresponding to ``service_id`` that have privilege information.

## Constructor Details

### - (`Operation`) initialize(config)

Constructs a new instance.

Parameters:

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

  A hash with the api provider details.

    72
    73
    74
    # File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/vapi/metadata/privilege/service.rb', line 72

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

## Instance Method Details

### - (`Com::Vmware::Vapi::Metadata::Privilege::OperationInfo`) get(service_id, operation_id)

Retrieves the privilege information about an operation element corresponding to ``operation_id`` contained in the service element corresponding to ``service_id`` .

Parameters:

- service_id (`String`) —

  Identifier of the service element.

- operation_id (`String`) —

  Identifier of the operation element.

Returns:

- (`Com::Vmware::Vapi::Metadata::Privilege::OperationInfo`) —

  The :class:`Com::Vmware::Vapi::Metadata::Privilege::OperationInfo` instance that corresponds to ``operation_id`` .

Raises:

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

  if the service element associated with ``service_id`` does not exist.

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

  if the operation element associated with ``operation_id`` does not exist.

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

  if the operation element associated with ``operation_id`` does not have any privilege information.

    108
    109
    110
    111
    112
    113
    # File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/vapi/metadata/privilege/service.rb', line 108

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

### - (`Array<String>`) list(service_id)

Returns the identifiers for the operation elements contained in the service element corresponding to ``service_id`` that have privilege information.

Parameters:

- service_id (`String`) —

  Identifier of the service element.

Returns:

- (`Array<String>`) —

  List of identifiers for the operation elements contained in the service element that have privilege information.

Raises:

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

  if the service element associated with ``service_id`` does not have any operation elements that have privilege information.

    87
    88
    89
    90
    91
    # File '/build/mts/release/bora-4571906/build/sdk/aggregated-bindings/ruby/com/vmware/vapi/metadata/privilege/service.rb', line 87

    def list(service_id)
        invoke_with_info(@@list_info, {
            'service_id' => service_id,
        })
    end