Package io.deephaven.protobuf
Class FieldOptions
java.lang.Object
io.deephaven.protobuf.FieldOptions
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic interface
static interface
The behavior when handling a protobufbytes
field.static interface
The behavior when handling a protobufmap
field.static interface
The behavior when handling a protobufmessage
type. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic FieldOptions.Builder
builder()
bytes()
Thebytes
type behavior.static FieldOptions
defaults()
The defaults options.static FieldOptions
exclude()
Creates the options to exclude a field.boolean
include()
If the field should be included for parsing.static Function<FieldPath,
FieldOptions> Creates a field options function that maps theinclude
predicate toinclude()
.map()
Themap
type behavior.The well-known message behavior.
-
Constructor Details
-
FieldOptions
public FieldOptions()
-
-
Method Details
-
builder
-
defaults
The defaults options. Equivalent tobuilder().build()
.- Returns:
- the default options
-
exclude
Creates the options to exclude a field. Equivalent tobuilder().include(false).build()
.- Returns:
- the options to exclude a field
-
includeIf
Creates a field options function that maps theinclude
predicate toinclude()
. Equivalent tofp -> builder().include(include.test(fp)).build()
.- Parameters:
include
- the include function- Returns:
- the field path functions
-
include
@Default public boolean include()If the field should be included for parsing. By default, istrue
.- Returns:
- if the field should be included
-
wellKnown
The well-known message behavior. By default, isFieldOptions.WellKnownBehavior.asWellKnown()
.- Returns:
- the well-known message behavior
-
bytes
Thebytes
type behavior. By default, isFieldOptions.BytesBehavior.asByteArray()
.- Returns:
- the bytes field behavior
-
map
Themap
type behavior. By default, isFieldOptions.MapBehavior.asMap()
.- Returns:
- the map field behavior.
-