static enum WireFormat.Utf8Validation extends java.lang.Enum<WireFormat.Utf8Validation>
Enum Constant and Description |
---|
LAZY
Keep data as ByteString; validation/conversion to String is lazy.
|
LOOSE
Eagerly parses to String; silently accepts invalid UTF8 bytes.
|
STRICT
Eagerly parses to String; throws an IOException on invalid bytes.
|
Modifier and Type | Method and Description |
---|---|
(package private) abstract java.lang.Object |
readString(CodedInputStream input)
Read a string field from the input with the proper UTF8 validation.
|
static WireFormat.Utf8Validation |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static WireFormat.Utf8Validation[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final WireFormat.Utf8Validation LOOSE
public static final WireFormat.Utf8Validation STRICT
public static final WireFormat.Utf8Validation LAZY
public static WireFormat.Utf8Validation[] values()
for (WireFormat.Utf8Validation c : WireFormat.Utf8Validation.values()) System.out.println(c);
public static WireFormat.Utf8Validation valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is nullabstract java.lang.Object readString(CodedInputStream input) throws java.io.IOException
java.io.IOException