target.apidocs.com.google.api.services.pubsub.model.AvroConfig.html Maven / Gradle / Ivy
AvroConfig (Cloud Pub/Sub API v1-rev20240918-2.0.0)
com.google.api.services.pubsub.model
Class AvroConfig
- java.lang.Object
-
- java.util.AbstractMap<String,Object>
-
- com.google.api.client.util.GenericData
-
- com.google.api.client.json.GenericJson
-
- com.google.api.services.pubsub.model.AvroConfig
-
public final class AvroConfig
extends com.google.api.client.json.GenericJson
Configuration for writing message data in Avro format. Message payloads and metadata will be
written to files as an Avro binary.
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 Cloud Pub/Sub 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
AvroConfig()
-
Method Summary
All Methods Instance Methods Concrete Methods
Modifier and Type
Method and Description
AvroConfig
clone()
Boolean
getUseTopicSchema()
Optional.
Boolean
getWriteMetadata()
Optional.
AvroConfig
set(String fieldName,
Object value)
AvroConfig
setUseTopicSchema(Boolean useTopicSchema)
Optional.
AvroConfig
setWriteMetadata(Boolean writeMetadata)
Optional.
-
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
-
getUseTopicSchema
public Boolean getUseTopicSchema()
Optional. When true, the output Cloud Storage file will be serialized using the topic schema,
if it exists.
- Returns:
- value or
null
for none
-
setUseTopicSchema
public AvroConfig setUseTopicSchema(Boolean useTopicSchema)
Optional. When true, the output Cloud Storage file will be serialized using the topic schema,
if it exists.
- Parameters:
useTopicSchema
- useTopicSchema or null
for none
-
getWriteMetadata
public Boolean getWriteMetadata()
Optional. When true, write the subscription name, message_id, publish_time, attributes, and
ordering_key as additional fields in the output. The subscription name, message_id, and
publish_time fields are put in their own fields while all other message properties other than
data (for example, an ordering_key, if present) are added as entries in the attributes map.
- Returns:
- value or
null
for none
-
setWriteMetadata
public AvroConfig setWriteMetadata(Boolean writeMetadata)
Optional. When true, write the subscription name, message_id, publish_time, attributes, and
ordering_key as additional fields in the output. The subscription name, message_id, and
publish_time fields are put in their own fields while all other message properties other than
data (for example, an ordering_key, if present) are added as entries in the attributes map.
- Parameters:
writeMetadata
- writeMetadata or null
for none
-
set
public AvroConfig set(String fieldName,
Object value)
- Overrides:
set
in class com.google.api.client.json.GenericJson
-
clone
public AvroConfig clone()
- Overrides:
clone
in class com.google.api.client.json.GenericJson
Copyright © 2011–2024 Google. All rights reserved.