target.apidocs.com.google.api.services.servicemanagement.model.Usage.html Maven / Gradle / Ivy
Usage (Service Management API v1-rev20240823-2.0.0)
com.google.api.services.servicemanagement.model
Class Usage
- java.lang.Object
-
- java.util.AbstractMap<String,Object>
-
- com.google.api.client.util.GenericData
-
- com.google.api.client.json.GenericJson
-
- com.google.api.services.servicemanagement.model.Usage
-
public final class Usage
extends com.google.api.client.json.GenericJson
Configuration controlling usage of a service.
This is the Java data model class that specifies how to parse/serialize into the JSON that is
transmitted over HTTP when working with the Service Management API. For a detailed explanation
see:
https://developers.google.com/api-client-library/java/google-http-java-client/json
- Author:
- Google, Inc.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.google.api.client.util.GenericData
com.google.api.client.util.GenericData.Flags
-
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>
-
Constructor Summary
Constructors
Constructor and Description
Usage()
-
Method Summary
All Methods Instance Methods Concrete Methods
Modifier and Type
Method and Description
Usage
clone()
String
getProducerNotificationChannel()
The full resource name of a channel used for sending notifications to the service producer.
List<String>
getRequirements()
Requirements that must be satisfied before a consumer project can use the service.
List<UsageRule>
getRules()
A list of usage rules that apply to individual API methods.
Usage
set(String fieldName,
Object value)
Usage
setProducerNotificationChannel(String producerNotificationChannel)
The full resource name of a channel used for sending notifications to the service producer.
Usage
setRequirements(List<String> requirements)
Requirements that must be satisfied before a consumer project can use the service.
Usage
setRules(List<UsageRule> rules)
A list of usage rules that apply to individual API methods.
-
Methods inherited from class com.google.api.client.json.GenericJson
getFactory, setFactory, toPrettyString, toString
-
Methods inherited from class com.google.api.client.util.GenericData
entrySet, equals, get, getClassInfo, getUnknownKeys, hashCode, put, putAll, remove, setUnknownKeys
-
Methods inherited from class java.util.AbstractMap
clear, containsKey, containsValue, isEmpty, keySet, size, values
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
-
-
Method Detail
-
getProducerNotificationChannel
public String getProducerNotificationChannel()
The full resource name of a channel used for sending notifications to the service producer.
Google Service Management currently only supports [Google Cloud
Pub/Sub](https://cloud.google.com/pubsub) as a notification channel. To use Google Cloud
Pub/Sub as the channel, this must be the name of a Cloud Pub/Sub topic that uses the Cloud
Pub/Sub topic name format documented in https://cloud.google.com/pubsub/docs/overview.
- Returns:
- value or
null
for none
-
setProducerNotificationChannel
public Usage setProducerNotificationChannel(String producerNotificationChannel)
The full resource name of a channel used for sending notifications to the service producer.
Google Service Management currently only supports [Google Cloud
Pub/Sub](https://cloud.google.com/pubsub) as a notification channel. To use Google Cloud
Pub/Sub as the channel, this must be the name of a Cloud Pub/Sub topic that uses the Cloud
Pub/Sub topic name format documented in https://cloud.google.com/pubsub/docs/overview.
- Parameters:
producerNotificationChannel
- producerNotificationChannel or null
for none
-
getRequirements
public List<String> getRequirements()
Requirements that must be satisfied before a consumer project can use the service. Each
requirement is of the form /; for example 'serviceusage.googleapis.com/billing-enabled'. For
Google APIs, a Terms of Service requirement must be included here. Google Cloud APIs must
include "serviceusage.googleapis.com/tos/cloud". Other Google APIs should include
"serviceusage.googleapis.com/tos/universal". Additional ToS can be included based on the
business needs.
- Returns:
- value or
null
for none
-
setRequirements
public Usage setRequirements(List<String> requirements)
Requirements that must be satisfied before a consumer project can use the service. Each
requirement is of the form /; for example 'serviceusage.googleapis.com/billing-enabled'. For
Google APIs, a Terms of Service requirement must be included here. Google Cloud APIs must
include "serviceusage.googleapis.com/tos/cloud". Other Google APIs should include
"serviceusage.googleapis.com/tos/universal". Additional ToS can be included based on the
business needs.
- Parameters:
requirements
- requirements or null
for none
-
getRules
public List<UsageRule> getRules()
A list of usage rules that apply to individual API methods. **NOTE:** All service configuration
rules follow "last one wins" order.
- Returns:
- value or
null
for none
-
setRules
public Usage setRules(List<UsageRule> rules)
A list of usage rules that apply to individual API methods. **NOTE:** All service configuration
rules follow "last one wins" order.
- Parameters:
rules
- rules or null
for none
-
set
public Usage set(String fieldName,
Object value)
- Overrides:
set
in class com.google.api.client.json.GenericJson
-
clone
public Usage clone()
- Overrides:
clone
in class com.google.api.client.json.GenericJson
Copyright © 2011–2024 Google. All rights reserved.
© 2015 - 2024 Weber Informatics LLC | Privacy Policy