Class: Aws::Comprehend::Types::Block

Inherits:
Struct
  • Object
show all
Includes:
Structure
Defined in:
lib/aws-sdk-comprehend/types.rb

Overview

Information about each word or line of text in the input document.

For additional information, see [Block] in the Amazon Textract API reference.

[1]: docs.aws.amazon.com/textract/latest/dg/API_Block.html

Constant Summary collapse

SENSITIVE =
[]

Instance Attribute Summary collapse

Instance Attribute Details

#block_typeString

The block represents a line of text or one word of text.

  • WORD - A word that’s detected on a document page. A word is one or more ISO basic Latin script characters that aren’t separated by spaces.

  • LINE - A string of tab-delimited, contiguous words that are detected on a document page

Returns:

  • (String)


557
558
559
560
561
562
563
564
565
566
# File 'lib/aws-sdk-comprehend/types.rb', line 557

class Block < Struct.new(
  :id,
  :block_type,
  :text,
  :page,
  :geometry,
  :relationships)
  SENSITIVE = []
  include Aws::Structure
end

#geometryTypes::Geometry

Co-ordinates of the rectangle or polygon that contains the text.

Returns:



557
558
559
560
561
562
563
564
565
566
# File 'lib/aws-sdk-comprehend/types.rb', line 557

class Block < Struct.new(
  :id,
  :block_type,
  :text,
  :page,
  :geometry,
  :relationships)
  SENSITIVE = []
  include Aws::Structure
end

#idString

Unique identifier for the block.

Returns:

  • (String)


557
558
559
560
561
562
563
564
565
566
# File 'lib/aws-sdk-comprehend/types.rb', line 557

class Block < Struct.new(
  :id,
  :block_type,
  :text,
  :page,
  :geometry,
  :relationships)
  SENSITIVE = []
  include Aws::Structure
end

#pageInteger

Page number where the block appears.

Returns:

  • (Integer)


557
558
559
560
561
562
563
564
565
566
# File 'lib/aws-sdk-comprehend/types.rb', line 557

class Block < Struct.new(
  :id,
  :block_type,
  :text,
  :page,
  :geometry,
  :relationships)
  SENSITIVE = []
  include Aws::Structure
end

#relationshipsArray<Types::RelationshipsListItem>

A list of child blocks of the current block. For example, a LINE object has child blocks for each WORD block that’s part of the line of text.

Returns:



557
558
559
560
561
562
563
564
565
566
# File 'lib/aws-sdk-comprehend/types.rb', line 557

class Block < Struct.new(
  :id,
  :block_type,
  :text,
  :page,
  :geometry,
  :relationships)
  SENSITIVE = []
  include Aws::Structure
end

#textString

The word or line of text extracted from the block.

Returns:

  • (String)


557
558
559
560
561
562
563
564
565
566
# File 'lib/aws-sdk-comprehend/types.rb', line 557

class Block < Struct.new(
  :id,
  :block_type,
  :text,
  :page,
  :geometry,
  :relationships)
  SENSITIVE = []
  include Aws::Structure
end