Package org.apache.avro.ipc
Class HandshakeRequest.Builder
java.lang.Object
org.apache.avro.data.RecordBuilderBase<HandshakeRequest>
org.apache.avro.specific.SpecificRecordBuilderBase<HandshakeRequest>
org.apache.avro.ipc.HandshakeRequest.Builder
- All Implemented Interfaces:
RecordBuilder<HandshakeRequest>
- Enclosing class:
HandshakeRequest
public static class HandshakeRequest.Builder
extends SpecificRecordBuilderBase<HandshakeRequest>
implements RecordBuilder<HandshakeRequest>
RecordBuilder for HandshakeRequest instances.
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Constructs a new instance using the values set in the RecordBuilder.Clears the value of the 'clientHash' field.Clears the value of the 'clientProtocol' field.Clears the value of the 'meta' field.Clears the value of the 'serverHash' field.Gets the value of the 'clientHash' field.Gets the value of the 'clientProtocol' field.getMeta()
Gets the value of the 'meta' field.Gets the value of the 'clientHash' field as an Optional<org.apache.avro.ipc.MD5>.Gets the value of the 'clientProtocol' field as an Optional<java.lang.String>.Gets the value of the 'meta' field as an Optional<java.util.Map<java.lang.String,java.nio.ByteBuffer>>.Gets the value of the 'serverHash' field as an Optional<org.apache.avro.ipc.MD5>.Gets the value of the 'serverHash' field.boolean
Checks whether the 'clientHash' field has been set.boolean
Checks whether the 'clientProtocol' field has been set.boolean
hasMeta()
Checks whether the 'meta' field has been set.boolean
Checks whether the 'serverHash' field has been set.setClientHash
(MD5 value) Sets the value of the 'clientHash' field.setClientProtocol
(String value) Sets the value of the 'clientProtocol' field.setMeta
(Map<String, ByteBuffer> value) Sets the value of the 'meta' field.setServerHash
(MD5 value) Sets the value of the 'serverHash' field.Methods inherited from class org.apache.avro.data.RecordBuilderBase
data, defaultValue, equals, fields, fieldSetFlags, hashCode, isValidValue, schema, validate
-
Method Details
-
getClientHash
Gets the value of the 'clientHash' field.- Returns:
- The value.
-
getOptionalClientHash
Gets the value of the 'clientHash' field as an Optional<org.apache.avro.ipc.MD5>.- Returns:
- The value wrapped in an Optional<org.apache.avro.ipc.MD5>.
-
setClientHash
Sets the value of the 'clientHash' field.- Parameters:
value
- The value of 'clientHash'.- Returns:
- This builder.
-
hasClientHash
public boolean hasClientHash()Checks whether the 'clientHash' field has been set.- Returns:
- True if the 'clientHash' field has been set, false otherwise.
-
clearClientHash
Clears the value of the 'clientHash' field.- Returns:
- This builder.
-
getClientProtocol
Gets the value of the 'clientProtocol' field.- Returns:
- The value.
-
getOptionalClientProtocol
Gets the value of the 'clientProtocol' field as an Optional<java.lang.String>.- Returns:
- The value wrapped in an Optional<java.lang.String>.
-
setClientProtocol
Sets the value of the 'clientProtocol' field.- Parameters:
value
- The value of 'clientProtocol'.- Returns:
- This builder.
-
hasClientProtocol
public boolean hasClientProtocol()Checks whether the 'clientProtocol' field has been set.- Returns:
- True if the 'clientProtocol' field has been set, false otherwise.
-
clearClientProtocol
Clears the value of the 'clientProtocol' field.- Returns:
- This builder.
-
getServerHash
Gets the value of the 'serverHash' field.- Returns:
- The value.
-
getOptionalServerHash
Gets the value of the 'serverHash' field as an Optional<org.apache.avro.ipc.MD5>.- Returns:
- The value wrapped in an Optional<org.apache.avro.ipc.MD5>.
-
setServerHash
Sets the value of the 'serverHash' field.- Parameters:
value
- The value of 'serverHash'.- Returns:
- This builder.
-
hasServerHash
public boolean hasServerHash()Checks whether the 'serverHash' field has been set.- Returns:
- True if the 'serverHash' field has been set, false otherwise.
-
clearServerHash
Clears the value of the 'serverHash' field.- Returns:
- This builder.
-
getMeta
Gets the value of the 'meta' field.- Returns:
- The value.
-
getOptionalMeta
Gets the value of the 'meta' field as an Optional<java.util.Map<java.lang.String,java.nio.ByteBuffer>>.- Returns:
- The value wrapped in an Optional<java.util.Map<java.lang.String,java.nio.ByteBuffer>>.
-
setMeta
Sets the value of the 'meta' field.- Parameters:
value
- The value of 'meta'.- Returns:
- This builder.
-
hasMeta
public boolean hasMeta()Checks whether the 'meta' field has been set.- Returns:
- True if the 'meta' field has been set, false otherwise.
-
clearMeta
Clears the value of the 'meta' field.- Returns:
- This builder.
-
build
Description copied from interface:RecordBuilder
Constructs a new instance using the values set in the RecordBuilder. If a particular value was not set and the schema defines a default value, the default value will be used.- Specified by:
build
in interfaceRecordBuilder<HandshakeRequest>
- Returns:
- a new instance using values set in the RecordBuilder.
-