public static final class JavaScriptUDF.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<JavaScriptUDF.Builder> implements JavaScriptUDFOrBuilder
User-defined JavaScript function that can transform or filter a Pub/Sub message.Protobuf type
google.cloud.bigquery.analyticshub.v1.JavaScriptUDF| Modifier and Type | Method and Description |
|---|---|
JavaScriptUDF.Builder |
addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) |
JavaScriptUDF |
build() |
JavaScriptUDF |
buildPartial() |
JavaScriptUDF.Builder |
clear() |
JavaScriptUDF.Builder |
clearCode()
Required.
|
JavaScriptUDF.Builder |
clearField(com.google.protobuf.Descriptors.FieldDescriptor field) |
JavaScriptUDF.Builder |
clearFunctionName()
Required.
|
JavaScriptUDF.Builder |
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) |
JavaScriptUDF.Builder |
clone() |
String |
getCode()
Required.
|
com.google.protobuf.ByteString |
getCodeBytes()
Required.
|
JavaScriptUDF |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
com.google.protobuf.Descriptors.Descriptor |
getDescriptorForType() |
String |
getFunctionName()
Required.
|
com.google.protobuf.ByteString |
getFunctionNameBytes()
Required.
|
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
JavaScriptUDF.Builder |
mergeFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
JavaScriptUDF.Builder |
mergeFrom(JavaScriptUDF other) |
JavaScriptUDF.Builder |
mergeFrom(com.google.protobuf.Message other) |
JavaScriptUDF.Builder |
mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
JavaScriptUDF.Builder |
setCode(String value)
Required.
|
JavaScriptUDF.Builder |
setCodeBytes(com.google.protobuf.ByteString value)
Required.
|
JavaScriptUDF.Builder |
setField(com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) |
JavaScriptUDF.Builder |
setFunctionName(String value)
Required.
|
JavaScriptUDF.Builder |
setFunctionNameBytes(com.google.protobuf.ByteString value)
Required.
|
JavaScriptUDF.Builder |
setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
int index,
Object value) |
JavaScriptUDF.Builder |
setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setUnknownFieldSetBuilder, setUnknownFieldsProto3findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringaddAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, newUninitializedMessageExceptionequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitpublic static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<JavaScriptUDF.Builder>public JavaScriptUDF.Builder clear()
clear in interface com.google.protobuf.Message.Builderclear in interface com.google.protobuf.MessageLite.Builderclear in class com.google.protobuf.GeneratedMessageV3.Builder<JavaScriptUDF.Builder>public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
getDescriptorForType in interface com.google.protobuf.Message.BuildergetDescriptorForType in interface com.google.protobuf.MessageOrBuildergetDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<JavaScriptUDF.Builder>public JavaScriptUDF getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderpublic JavaScriptUDF build()
build in interface com.google.protobuf.Message.Builderbuild in interface com.google.protobuf.MessageLite.Builderpublic JavaScriptUDF buildPartial()
buildPartial in interface com.google.protobuf.Message.BuilderbuildPartial in interface com.google.protobuf.MessageLite.Builderpublic JavaScriptUDF.Builder clone()
clone in interface com.google.protobuf.Message.Builderclone in interface com.google.protobuf.MessageLite.Builderclone in class com.google.protobuf.GeneratedMessageV3.Builder<JavaScriptUDF.Builder>public JavaScriptUDF.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
setField in interface com.google.protobuf.Message.BuildersetField in class com.google.protobuf.GeneratedMessageV3.Builder<JavaScriptUDF.Builder>public JavaScriptUDF.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
clearField in interface com.google.protobuf.Message.BuilderclearField in class com.google.protobuf.GeneratedMessageV3.Builder<JavaScriptUDF.Builder>public JavaScriptUDF.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
clearOneof in interface com.google.protobuf.Message.BuilderclearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<JavaScriptUDF.Builder>public JavaScriptUDF.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
setRepeatedField in interface com.google.protobuf.Message.BuildersetRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<JavaScriptUDF.Builder>public JavaScriptUDF.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
addRepeatedField in interface com.google.protobuf.Message.BuilderaddRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<JavaScriptUDF.Builder>public JavaScriptUDF.Builder mergeFrom(com.google.protobuf.Message other)
mergeFrom in interface com.google.protobuf.Message.BuildermergeFrom in class com.google.protobuf.AbstractMessage.Builder<JavaScriptUDF.Builder>public JavaScriptUDF.Builder mergeFrom(JavaScriptUDF other)
public final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<JavaScriptUDF.Builder>public JavaScriptUDF.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
mergeFrom in interface com.google.protobuf.Message.BuildermergeFrom in interface com.google.protobuf.MessageLite.BuildermergeFrom in class com.google.protobuf.AbstractMessage.Builder<JavaScriptUDF.Builder>IOExceptionpublic String getFunctionName()
Required. Name of the JavasScript function that should applied to Pub/Sub messages.
string function_name = 1 [(.google.api.field_behavior) = REQUIRED];getFunctionName in interface JavaScriptUDFOrBuilderpublic com.google.protobuf.ByteString getFunctionNameBytes()
Required. Name of the JavasScript function that should applied to Pub/Sub messages.
string function_name = 1 [(.google.api.field_behavior) = REQUIRED];getFunctionNameBytes in interface JavaScriptUDFOrBuilderpublic JavaScriptUDF.Builder setFunctionName(String value)
Required. Name of the JavasScript function that should applied to Pub/Sub messages.
string function_name = 1 [(.google.api.field_behavior) = REQUIRED];value - The functionName to set.public JavaScriptUDF.Builder clearFunctionName()
Required. Name of the JavasScript function that should applied to Pub/Sub messages.
string function_name = 1 [(.google.api.field_behavior) = REQUIRED];public JavaScriptUDF.Builder setFunctionNameBytes(com.google.protobuf.ByteString value)
Required. Name of the JavasScript function that should applied to Pub/Sub messages.
string function_name = 1 [(.google.api.field_behavior) = REQUIRED];value - The bytes for functionName to set.public String getCode()
Required. JavaScript code that contains a function `function_name` with the
below signature:
```
/**
* Transforms a Pub/Sub message.
* @return {(Object<string, (string | Object<string, string>)>|null)} - To
* filter a message, return `null`. To transform a message return a map
* with the following keys:
* - (required) 'data' : {string}
* - (optional) 'attributes' : {Object<string, string>}
* Returning empty `attributes` will remove all attributes from the
* message.
*
* @param {(Object<string, (string | Object<string, string>)>} Pub/Sub
* message. Keys:
* - (required) 'data' : {string}
* - (required) 'attributes' : {Object<string, string>}
*
* @param {Object<string, any>} metadata - Pub/Sub message metadata.
* Keys:
* - (required) 'message_id' : {string}
* - (optional) 'publish_time': {string} YYYY-MM-DDTHH:MM:SSZ format
* - (optional) 'ordering_key': {string}
*/
function <function_name>(message, metadata) {
}
```
string code = 2 [(.google.api.field_behavior) = REQUIRED];getCode in interface JavaScriptUDFOrBuilderpublic com.google.protobuf.ByteString getCodeBytes()
Required. JavaScript code that contains a function `function_name` with the
below signature:
```
/**
* Transforms a Pub/Sub message.
* @return {(Object<string, (string | Object<string, string>)>|null)} - To
* filter a message, return `null`. To transform a message return a map
* with the following keys:
* - (required) 'data' : {string}
* - (optional) 'attributes' : {Object<string, string>}
* Returning empty `attributes` will remove all attributes from the
* message.
*
* @param {(Object<string, (string | Object<string, string>)>} Pub/Sub
* message. Keys:
* - (required) 'data' : {string}
* - (required) 'attributes' : {Object<string, string>}
*
* @param {Object<string, any>} metadata - Pub/Sub message metadata.
* Keys:
* - (required) 'message_id' : {string}
* - (optional) 'publish_time': {string} YYYY-MM-DDTHH:MM:SSZ format
* - (optional) 'ordering_key': {string}
*/
function <function_name>(message, metadata) {
}
```
string code = 2 [(.google.api.field_behavior) = REQUIRED];getCodeBytes in interface JavaScriptUDFOrBuilderpublic JavaScriptUDF.Builder setCode(String value)
Required. JavaScript code that contains a function `function_name` with the
below signature:
```
/**
* Transforms a Pub/Sub message.
* @return {(Object<string, (string | Object<string, string>)>|null)} - To
* filter a message, return `null`. To transform a message return a map
* with the following keys:
* - (required) 'data' : {string}
* - (optional) 'attributes' : {Object<string, string>}
* Returning empty `attributes` will remove all attributes from the
* message.
*
* @param {(Object<string, (string | Object<string, string>)>} Pub/Sub
* message. Keys:
* - (required) 'data' : {string}
* - (required) 'attributes' : {Object<string, string>}
*
* @param {Object<string, any>} metadata - Pub/Sub message metadata.
* Keys:
* - (required) 'message_id' : {string}
* - (optional) 'publish_time': {string} YYYY-MM-DDTHH:MM:SSZ format
* - (optional) 'ordering_key': {string}
*/
function <function_name>(message, metadata) {
}
```
string code = 2 [(.google.api.field_behavior) = REQUIRED];value - The code to set.public JavaScriptUDF.Builder clearCode()
Required. JavaScript code that contains a function `function_name` with the
below signature:
```
/**
* Transforms a Pub/Sub message.
* @return {(Object<string, (string | Object<string, string>)>|null)} - To
* filter a message, return `null`. To transform a message return a map
* with the following keys:
* - (required) 'data' : {string}
* - (optional) 'attributes' : {Object<string, string>}
* Returning empty `attributes` will remove all attributes from the
* message.
*
* @param {(Object<string, (string | Object<string, string>)>} Pub/Sub
* message. Keys:
* - (required) 'data' : {string}
* - (required) 'attributes' : {Object<string, string>}
*
* @param {Object<string, any>} metadata - Pub/Sub message metadata.
* Keys:
* - (required) 'message_id' : {string}
* - (optional) 'publish_time': {string} YYYY-MM-DDTHH:MM:SSZ format
* - (optional) 'ordering_key': {string}
*/
function <function_name>(message, metadata) {
}
```
string code = 2 [(.google.api.field_behavior) = REQUIRED];public JavaScriptUDF.Builder setCodeBytes(com.google.protobuf.ByteString value)
Required. JavaScript code that contains a function `function_name` with the
below signature:
```
/**
* Transforms a Pub/Sub message.
* @return {(Object<string, (string | Object<string, string>)>|null)} - To
* filter a message, return `null`. To transform a message return a map
* with the following keys:
* - (required) 'data' : {string}
* - (optional) 'attributes' : {Object<string, string>}
* Returning empty `attributes` will remove all attributes from the
* message.
*
* @param {(Object<string, (string | Object<string, string>)>} Pub/Sub
* message. Keys:
* - (required) 'data' : {string}
* - (required) 'attributes' : {Object<string, string>}
*
* @param {Object<string, any>} metadata - Pub/Sub message metadata.
* Keys:
* - (required) 'message_id' : {string}
* - (optional) 'publish_time': {string} YYYY-MM-DDTHH:MM:SSZ format
* - (optional) 'ordering_key': {string}
*/
function <function_name>(message, metadata) {
}
```
string code = 2 [(.google.api.field_behavior) = REQUIRED];value - The bytes for code to set.public final JavaScriptUDF.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
setUnknownFields in interface com.google.protobuf.Message.BuildersetUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<JavaScriptUDF.Builder>public final JavaScriptUDF.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
mergeUnknownFields in interface com.google.protobuf.Message.BuildermergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<JavaScriptUDF.Builder>Copyright © 2025 Google LLC. All rights reserved.