Interface DynamicMessageBuilder
Deprecated.
Interface to hide away the annoying details of building a Dynamic Message from a descriptor.
TODO (yhatem) if we want to keep using this API, we can now heavily simplify it, because we can easily deduce the
descriptor of a nested field using the fields _name_ instead of, somewhat incorrectly, using the
descriptor name (the struct reference), since that's an internal representation.
See usages of this this API in some tests such as
SimpleDirectAccessInsertionTests
for more
information.-
Method Summary
Modifier and TypeMethodDescriptionaddRepeatedField
(int fieldNumber, Object value) Deprecated.addRepeatedField
(String fieldName, Object value) Deprecated.addRepeatedFields
(int fieldNumber, Iterable<? extends Object> value) Deprecated.addRepeatedFields
(String fieldName, Iterable<? extends Object> value) Deprecated.addRepeatedFields
(String fieldName, Iterable<? extends Object> value, boolean isNullableArray) Deprecated.build()
Deprecated.convertMessage
(T m) Deprecated.Deprecated.Deprecated.getFieldType
(String fieldName) Deprecated.Get the type for the specified field, or throw an error if the field doesn't exist.getNestedMessageBuilder
(int fieldNumber) Deprecated.getNestedMessageBuilder
(String fieldName) Deprecated.boolean
isPrimitive
(int fieldNumber) Deprecated.Deprecated.Deprecated.Deprecated.
-
Method Details
-
getFieldNames
Deprecated. -
getFieldType
Deprecated.Get the type for the specified field, or throw an error if the field doesn't exist.- Parameters:
fieldName
- the name of the field to get the type for- Returns:
- the string name of the type that the field is.
- Throws:
SQLException
- withErrorCode.INVALID_PARAMETER
if the field does not exist.
-
isPrimitive
Deprecated.- Throws:
SQLException
-
setField
Deprecated.- Throws:
SQLException
-
setField
Deprecated.- Throws:
SQLException
-
addRepeatedField
Deprecated.- Throws:
SQLException
-
addRepeatedField
Deprecated.- Throws:
SQLException
-
addRepeatedFields
DynamicMessageBuilder addRepeatedFields(String fieldName, Iterable<? extends Object> value, boolean isNullableArray) throws SQLException Deprecated.- Throws:
SQLException
-
addRepeatedFields
DynamicMessageBuilder addRepeatedFields(String fieldName, Iterable<? extends Object> value) throws SQLException Deprecated.- Throws:
SQLException
-
addRepeatedFields
DynamicMessageBuilder addRepeatedFields(int fieldNumber, Iterable<? extends Object> value) throws SQLException Deprecated.- Throws:
SQLException
-
build
Message build()Deprecated. -
convertMessage
Deprecated.- Throws:
SQLException
-
getNestedMessageBuilder
Deprecated.- Throws:
SQLException
-
getNestedMessageBuilder
Deprecated.- Throws:
SQLException
-
getDescriptor
Descriptors.Descriptor getDescriptor()Deprecated. -
newBuilder
Deprecated.
-