Class: Google::Apis::ApigeeV1::GoogleCloudApigeeV1Quota

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

Overview

Quota contains the essential parameters needed that can be applied on the resources, methods, API source combination associated with this API product. While Quota is optional, setting it prevents requests from exceeding the provisioned parameters.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudApigeeV1Quota

Returns a new instance of GoogleCloudApigeeV1Quota.



6167
6168
6169
# File 'lib/google/apis/apigee_v1/classes.rb', line 6167

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

Instance Attribute Details

#intervalString

Required. Time interval over which the number of request messages is calculated. Corresponds to the JSON property interval

Returns:

  • (String)


6152
6153
6154
# File 'lib/google/apis/apigee_v1/classes.rb', line 6152

def interval
  @interval
end

#limitString

Required. Upper limit allowed for the time interval and time unit specified. Requests exceeding this limit will be rejected. Corresponds to the JSON property limit

Returns:

  • (String)


6158
6159
6160
# File 'lib/google/apis/apigee_v1/classes.rb', line 6158

def limit
  @limit
end

#time_unitString

Time unit defined for the interval. Valid values include minute, hour, day, or month. If limit and interval are valid, the default value is hour; otherwise, the default is null. Corresponds to the JSON property timeUnit

Returns:

  • (String)


6165
6166
6167
# File 'lib/google/apis/apigee_v1/classes.rb', line 6165

def time_unit
  @time_unit
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



6172
6173
6174
6175
6176
# File 'lib/google/apis/apigee_v1/classes.rb', line 6172

def update!(**args)
  @interval = args[:interval] if args.key?(:interval)
  @limit = args[:limit] if args.key?(:limit)
  @time_unit = args[:time_unit] if args.key?(:time_unit)
end