public static final class SchemaSettings.Builder extends GeneratedMessage.Builder<SchemaSettings.Builder> implements SchemaSettingsOrBuilderSettings for validating messages published against a schema.
Protobuf type google.pubsub.v1.SchemaSettings
Inheritance
java.lang.Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessage.Builder > SchemaSettings.BuilderImplements
SchemaSettingsOrBuilderStatic Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
Methods
build()
public SchemaSettings build()| Returns | |
|---|---|
| Type | Description |
SchemaSettings |
|
buildPartial()
public SchemaSettings buildPartial()| Returns | |
|---|---|
| Type | Description |
SchemaSettings |
|
clear()
public SchemaSettings.Builder clear()| Returns | |
|---|---|
| Type | Description |
SchemaSettings.Builder |
|
clearEncoding()
public SchemaSettings.Builder clearEncoding() Optional. The encoding of messages validated against schema.
.google.pubsub.v1.Encoding encoding = 2 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
SchemaSettings.Builder |
This builder for chaining. |
clearFirstRevisionId()
public SchemaSettings.Builder clearFirstRevisionId()Optional. The minimum (inclusive) revision allowed for validating messages. If empty or not present, allow any revision to be validated against last_revision or any revision created before.
string first_revision_id = 3 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
SchemaSettings.Builder |
This builder for chaining. |
clearLastRevisionId()
public SchemaSettings.Builder clearLastRevisionId()Optional. The maximum (inclusive) revision allowed for validating messages. If empty or not present, allow any revision to be validated against first_revision or any revision created after.
string last_revision_id = 4 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
SchemaSettings.Builder |
This builder for chaining. |
clearSchema()
public SchemaSettings.Builder clearSchema() Required. The name of the schema that messages published should be
validated against. Format is projects/{project}/schemas/{schema}. The
value of this field will be deleted-schema if the schema has been
deleted.
string schema = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
| Returns | |
|---|---|
| Type | Description |
SchemaSettings.Builder |
This builder for chaining. |
getDefaultInstanceForType()
public SchemaSettings getDefaultInstanceForType()| Returns | |
|---|---|
| Type | Description |
SchemaSettings |
|
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
getEncoding()
public Encoding getEncoding() Optional. The encoding of messages validated against schema.
.google.pubsub.v1.Encoding encoding = 2 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
Encoding |
The encoding. |
getEncodingValue()
public int getEncodingValue() Optional. The encoding of messages validated against schema.
.google.pubsub.v1.Encoding encoding = 2 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
int |
The enum numeric value on the wire for encoding. |
getFirstRevisionId()
public String getFirstRevisionId()Optional. The minimum (inclusive) revision allowed for validating messages. If empty or not present, allow any revision to be validated against last_revision or any revision created before.
string first_revision_id = 3 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
String |
The firstRevisionId. |
getFirstRevisionIdBytes()
public ByteString getFirstRevisionIdBytes()Optional. The minimum (inclusive) revision allowed for validating messages. If empty or not present, allow any revision to be validated against last_revision or any revision created before.
string first_revision_id = 3 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
ByteString |
The bytes for firstRevisionId. |
getLastRevisionId()
public String getLastRevisionId()Optional. The maximum (inclusive) revision allowed for validating messages. If empty or not present, allow any revision to be validated against first_revision or any revision created after.
string last_revision_id = 4 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
String |
The lastRevisionId. |
getLastRevisionIdBytes()
public ByteString getLastRevisionIdBytes()Optional. The maximum (inclusive) revision allowed for validating messages. If empty or not present, allow any revision to be validated against first_revision or any revision created after.
string last_revision_id = 4 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
ByteString |
The bytes for lastRevisionId. |
getSchema()
public String getSchema() Required. The name of the schema that messages published should be
validated against. Format is projects/{project}/schemas/{schema}. The
value of this field will be deleted-schema if the schema has been
deleted.
string schema = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
| Returns | |
|---|---|
| Type | Description |
String |
The schema. |
getSchemaBytes()
public ByteString getSchemaBytes() Required. The name of the schema that messages published should be
validated against. Format is projects/{project}/schemas/{schema}. The
value of this field will be deleted-schema if the schema has been
deleted.
string schema = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
| Returns | |
|---|---|
| Type | Description |
ByteString |
The bytes for schema. |
internalGetFieldAccessorTable()
protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()| Returns | |
|---|---|
| Type | Description |
FieldAccessorTable |
|
isInitialized()
public final boolean isInitialized()| Returns | |
|---|---|
| Type | Description |
boolean |
|
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public SchemaSettings.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)| Parameters | |
|---|---|
| Name | Description |
input |
CodedInputStream |
extensionRegistry |
ExtensionRegistryLite |
| Returns | |
|---|---|
| Type | Description |
SchemaSettings.Builder |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
mergeFrom(Message other)
public SchemaSettings.Builder mergeFrom(Message other)| Parameter | |
|---|---|
| Name | Description |
other |
Message |
| Returns | |
|---|---|
| Type | Description |
SchemaSettings.Builder |
|
mergeFrom(SchemaSettings other)
public SchemaSettings.Builder mergeFrom(SchemaSettings other)| Parameter | |
|---|---|
| Name | Description |
other |
SchemaSettings |
| Returns | |
|---|---|
| Type | Description |
SchemaSettings.Builder |
|
setEncoding(Encoding value)
public SchemaSettings.Builder setEncoding(Encoding value) Optional. The encoding of messages validated against schema.
.google.pubsub.v1.Encoding encoding = 2 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
EncodingThe encoding to set. |
| Returns | |
|---|---|
| Type | Description |
SchemaSettings.Builder |
This builder for chaining. |
setEncodingValue(int value)
public SchemaSettings.Builder setEncodingValue(int value) Optional. The encoding of messages validated against schema.
.google.pubsub.v1.Encoding encoding = 2 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
intThe enum numeric value on the wire for encoding to set. |
| Returns | |
|---|---|
| Type | Description |
SchemaSettings.Builder |
This builder for chaining. |
setFirstRevisionId(String value)
public SchemaSettings.Builder setFirstRevisionId(String value)Optional. The minimum (inclusive) revision allowed for validating messages. If empty or not present, allow any revision to be validated against last_revision or any revision created before.
string first_revision_id = 3 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
StringThe firstRevisionId to set. |
| Returns | |
|---|---|
| Type | Description |
SchemaSettings.Builder |
This builder for chaining. |
setFirstRevisionIdBytes(ByteString value)
public SchemaSettings.Builder setFirstRevisionIdBytes(ByteString value)Optional. The minimum (inclusive) revision allowed for validating messages. If empty or not present, allow any revision to be validated against last_revision or any revision created before.
string first_revision_id = 3 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
ByteStringThe bytes for firstRevisionId to set. |
| Returns | |
|---|---|
| Type | Description |
SchemaSettings.Builder |
This builder for chaining. |
setLastRevisionId(String value)
public SchemaSettings.Builder setLastRevisionId(String value)Optional. The maximum (inclusive) revision allowed for validating messages. If empty or not present, allow any revision to be validated against first_revision or any revision created after.
string last_revision_id = 4 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
StringThe lastRevisionId to set. |
| Returns | |
|---|---|
| Type | Description |
SchemaSettings.Builder |
This builder for chaining. |
setLastRevisionIdBytes(ByteString value)
public SchemaSettings.Builder setLastRevisionIdBytes(ByteString value)Optional. The maximum (inclusive) revision allowed for validating messages. If empty or not present, allow any revision to be validated against first_revision or any revision created after.
string last_revision_id = 4 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
ByteStringThe bytes for lastRevisionId to set. |
| Returns | |
|---|---|
| Type | Description |
SchemaSettings.Builder |
This builder for chaining. |
setSchema(String value)
public SchemaSettings.Builder setSchema(String value) Required. The name of the schema that messages published should be
validated against. Format is projects/{project}/schemas/{schema}. The
value of this field will be deleted-schema if the schema has been
deleted.
string schema = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
| Parameter | |
|---|---|
| Name | Description |
value |
StringThe schema to set. |
| Returns | |
|---|---|
| Type | Description |
SchemaSettings.Builder |
This builder for chaining. |
setSchemaBytes(ByteString value)
public SchemaSettings.Builder setSchemaBytes(ByteString value) Required. The name of the schema that messages published should be
validated against. Format is projects/{project}/schemas/{schema}. The
value of this field will be deleted-schema if the schema has been
deleted.
string schema = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
| Parameter | |
|---|---|
| Name | Description |
value |
ByteStringThe bytes for schema to set. |
| Returns | |
|---|---|
| Type | Description |
SchemaSettings.Builder |
This builder for chaining. |