Class: Google::Apis::CloudidentityV1::MemberRestriction

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
lib/google/apis/cloudidentity_v1/classes.rb,
lib/google/apis/cloudidentity_v1/representations.rb,
lib/google/apis/cloudidentity_v1/representations.rb

Overview

The definition of MemberRestriction

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ MemberRestriction

Returns a new instance of MemberRestriction.



2031
2032
2033
# File 'lib/google/apis/cloudidentity_v1/classes.rb', line 2031

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#evaluationGoogle::Apis::CloudidentityV1::RestrictionEvaluation

The evaluated state of this restriction. Corresponds to the JSON property evaluation



2016
2017
2018
# File 'lib/google/apis/cloudidentity_v1/classes.rb', line 2016

def evaluation
  @evaluation
end

#queryString

Member Restriction as defined by CEL expression. Supported restrictions are: member.customer_id and member.type. Valid values for member.type are 1, 2 and 3. They correspond to USER, SERVICE_ACCOUNT, and GROUP respectively. The value for member.customer_id only supports groupCustomerId() currently which means the customer id of the group will be used for restriction. Supported operators are &&, || and ==, corresponding to AND, OR, and EQUAL. Examples: Allow only service accounts of given customer to be members. member.type == 2 && member.customer_id == groupCustomerId() Allow only users or groups to be members. member.type == 1 || member.type == 3 Corresponds to the JSON property query

Returns:

  • (String)


2029
2030
2031
# File 'lib/google/apis/cloudidentity_v1/classes.rb', line 2029

def query
  @query
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2036
2037
2038
2039
# File 'lib/google/apis/cloudidentity_v1/classes.rb', line 2036

def update!(**args)
  @evaluation = args[:evaluation] if args.key?(:evaluation)
  @query = args[:query] if args.key?(:query)
end