Enum Document.Layout.TextSegmentType

    • Enum Constant Detail

      • TEXT_SEGMENT_TYPE_UNSPECIFIED

        public static final Document.Layout.TextSegmentType TEXT_SEGMENT_TYPE_UNSPECIFIED
         Should not be used.
         
        TEXT_SEGMENT_TYPE_UNSPECIFIED = 0;
      • FORM_FIELD_NAME

        public static final Document.Layout.TextSegmentType FORM_FIELD_NAME
         The text segment is the name part of a form field. It will be treated
         as child of another FORM_FIELD TextSegment if its span is subspan of
         another TextSegment with type FORM_FIELD.
         
        FORM_FIELD_NAME = 4;
      • FORM_FIELD_CONTENTS

        public static final Document.Layout.TextSegmentType FORM_FIELD_CONTENTS
         The text segment is the text content part of a form field. It will be
         treated as child of another FORM_FIELD TextSegment if its span is
         subspan of another TextSegment with type FORM_FIELD.
         
        FORM_FIELD_CONTENTS = 5;
      • TABLE_HEADER

        public static final Document.Layout.TextSegmentType TABLE_HEADER
         The text segment is a table's headers. It will be treated as child of
         another TABLE TextSegment if its span is subspan of another TextSegment
         with type TABLE.
         
        TABLE_HEADER = 7;
      • TABLE_ROW

        public static final Document.Layout.TextSegmentType TABLE_ROW
         The text segment is a row in table. It will be treated as child of
         another TABLE TextSegment if its span is subspan of another TextSegment
         with type TABLE.
         
        TABLE_ROW = 8;
      • TABLE_CELL

        public static final Document.Layout.TextSegmentType TABLE_CELL
         The text segment is a cell in table. It will be treated as child of
         another TABLE_ROW TextSegment if its span is subspan of another
         TextSegment with type TABLE_ROW.
         
        TABLE_CELL = 9;
    • Field Detail

      • TEXT_SEGMENT_TYPE_UNSPECIFIED_VALUE

        public static final int TEXT_SEGMENT_TYPE_UNSPECIFIED_VALUE
         Should not be used.
         
        TEXT_SEGMENT_TYPE_UNSPECIFIED = 0;
        See Also:
        Constant Field Values
      • TOKEN_VALUE

        public static final int TOKEN_VALUE
         The text segment is a token. e.g. word.
         
        TOKEN = 1;
        See Also:
        Constant Field Values
      • PARAGRAPH_VALUE

        public static final int PARAGRAPH_VALUE
         The text segment is a paragraph.
         
        PARAGRAPH = 2;
        See Also:
        Constant Field Values
      • FORM_FIELD_VALUE

        public static final int FORM_FIELD_VALUE
         The text segment is a form field.
         
        FORM_FIELD = 3;
        See Also:
        Constant Field Values
      • FORM_FIELD_NAME_VALUE

        public static final int FORM_FIELD_NAME_VALUE
         The text segment is the name part of a form field. It will be treated
         as child of another FORM_FIELD TextSegment if its span is subspan of
         another TextSegment with type FORM_FIELD.
         
        FORM_FIELD_NAME = 4;
        See Also:
        Constant Field Values
      • FORM_FIELD_CONTENTS_VALUE

        public static final int FORM_FIELD_CONTENTS_VALUE
         The text segment is the text content part of a form field. It will be
         treated as child of another FORM_FIELD TextSegment if its span is
         subspan of another TextSegment with type FORM_FIELD.
         
        FORM_FIELD_CONTENTS = 5;
        See Also:
        Constant Field Values
      • TABLE_VALUE

        public static final int TABLE_VALUE
         The text segment is a whole table, including headers, and all rows.
         
        TABLE = 6;
        See Also:
        Constant Field Values
      • TABLE_HEADER_VALUE

        public static final int TABLE_HEADER_VALUE
         The text segment is a table's headers. It will be treated as child of
         another TABLE TextSegment if its span is subspan of another TextSegment
         with type TABLE.
         
        TABLE_HEADER = 7;
        See Also:
        Constant Field Values
      • TABLE_ROW_VALUE

        public static final int TABLE_ROW_VALUE
         The text segment is a row in table. It will be treated as child of
         another TABLE TextSegment if its span is subspan of another TextSegment
         with type TABLE.
         
        TABLE_ROW = 8;
        See Also:
        Constant Field Values
      • TABLE_CELL_VALUE

        public static final int TABLE_CELL_VALUE
         The text segment is a cell in table. It will be treated as child of
         another TABLE_ROW TextSegment if its span is subspan of another
         TextSegment with type TABLE_ROW.
         
        TABLE_CELL = 9;
        See Also:
        Constant Field Values
    • Method Detail

      • values

        public static Document.Layout.TextSegmentType[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (Document.Layout.TextSegmentType c : Document.Layout.TextSegmentType.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static Document.Layout.TextSegmentType valueOf​(String name)
        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 name
        NullPointerException - if the argument is null
      • getNumber

        public final int getNumber()
        Specified by:
        getNumber in interface com.google.protobuf.Internal.EnumLite
        Specified by:
        getNumber in interface com.google.protobuf.ProtocolMessageEnum
      • valueOf

        @Deprecated
        public static Document.Layout.TextSegmentType valueOf​(int value)
        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 name
        NullPointerException - if the argument is null
      • forNumber

        public static Document.Layout.TextSegmentType forNumber​(int value)
        Parameters:
        value - The numeric wire value of the corresponding enum entry.
        Returns:
        The enum associated with the given numeric wire value.
      • getValueDescriptor

        public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor()
        Specified by:
        getValueDescriptor in interface com.google.protobuf.ProtocolMessageEnum
      • getDescriptorForType

        public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType()
        Specified by:
        getDescriptorForType in interface com.google.protobuf.ProtocolMessageEnum
      • getDescriptor

        public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor()
      • valueOf

        public static Document.Layout.TextSegmentType valueOf​(com.google.protobuf.Descriptors.EnumValueDescriptor desc)
        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 name
        NullPointerException - if the argument is null