Package com.google.cloud.vision.v1
Enum Block.BlockType
- All Implemented Interfaces:
com.google.protobuf.Internal.EnumLite,com.google.protobuf.ProtocolMessageEnum,Serializable,Comparable<Block.BlockType>
- Enclosing class:
- Block
public static enum Block.BlockType
extends Enum<Block.BlockType>
implements com.google.protobuf.ProtocolMessageEnum
Type of a block (text, image etc) as identified by OCR.Protobuf enum
google.cloud.vision.v1.Block.BlockType-
Enum Constant Summary
Enum Constants -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intBarcode block.static final intImage block.static final intHorizontal/vertical line box.static final intTable block.static final intRegular text block.static final intUnknown block type. -
Method Summary
Modifier and TypeMethodDescriptionstatic Block.BlockTypeforNumber(int value) static com.google.protobuf.Descriptors.EnumDescriptorfinal com.google.protobuf.Descriptors.EnumDescriptorfinal intfinal com.google.protobuf.Descriptors.EnumValueDescriptorstatic com.google.protobuf.Internal.EnumLiteMap<Block.BlockType>static Block.BlockTypevalueOf(int value) Deprecated.static Block.BlockTypevalueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) Returns the enum constant of this type with the specified name.static Block.BlockTypeReturns the enum constant of this type with the specified name.static Block.BlockType[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
UNKNOWN
Unknown block type.
UNKNOWN = 0; -
TEXT
Regular text block.
TEXT = 1; -
TABLE
Table block.
TABLE = 2; -
PICTURE
Image block.
PICTURE = 3; -
RULER
Horizontal/vertical line box.
RULER = 4; -
BARCODE
Barcode block.
BARCODE = 5; -
UNRECOGNIZED
-
-
Field Details
-
UNKNOWN_VALUE
public static final int UNKNOWN_VALUEUnknown block type.
UNKNOWN = 0;- See Also:
-
TEXT_VALUE
public static final int TEXT_VALUERegular text block.
TEXT = 1;- See Also:
-
TABLE_VALUE
public static final int TABLE_VALUETable block.
TABLE = 2;- See Also:
-
PICTURE_VALUE
public static final int PICTURE_VALUEImage block.
PICTURE = 3;- See Also:
-
RULER_VALUE
public static final int RULER_VALUEHorizontal/vertical line box.
RULER = 4;- See Also:
-
BARCODE_VALUE
public static final int BARCODE_VALUEBarcode block.
BARCODE = 5;- See Also:
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
getNumber
public final int getNumber()- Specified by:
getNumberin interfacecom.google.protobuf.Internal.EnumLite- Specified by:
getNumberin interfacecom.google.protobuf.ProtocolMessageEnum
-
valueOf
Deprecated.Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
value- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
forNumber
- Parameters:
value- The numeric wire value of the corresponding enum entry.- Returns:
- The enum associated with the given numeric wire value.
-
internalGetValueMap
-
getValueDescriptor
public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor()- Specified by:
getValueDescriptorin interfacecom.google.protobuf.ProtocolMessageEnum
-
getDescriptorForType
public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.ProtocolMessageEnum
-
getDescriptor
public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() -
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
desc- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-