class Abbyy::Models::ProcessTextFieldRequest
- Abbyy::Models::ProcessTextFieldRequest
- Abbyy::Models::BaseRequest
- Abbyy::Models::BaseModel
- Reference
- Object
Overview
Request object for /processTextField API-method.
Included Modules
Defined in:
abbyy/models/process_text_field_request.crConstant Summary
-
ALLOWED_TEXT_TYPES =
TextType.values - [TextType::Handprinted] -
DEFAULT_DESCRIPTION =
"" -
DEFAULT_LANGUAGE =
Language::English -
DEFAULT_LETTER_SET =
"" -
DEFAULT_MARKING_TYPE =
FieldMarkingType::SimpleText -
DEFAULT_ONE_TEXT_LINE =
false -
DEFAULT_ONE_WORD_PER_TEXT_LINE =
false -
DEFAULT_PASSWORD =
"" -
DEFAULT_PLACEHOLDERS_COUNT =
1 -
DEFAULT_REG_EXP =
"" -
DEFAULT_REGION =
Region.new(-1, -1, -1, -1) -
DEFAULT_TEXT_TYPE =
TextType::Normal -
DEFAULT_WRITING_STYLE =
WritingStyle::Default
Constructors
Instance Method Summary
-
#description : String | Nil
Contains the description of the processing task.
- #description=(description : String | Nil)
-
#language : Language | Array(Language) | Nil
Specifies recognition language of the document.
-
#language=(language : Language | Array(Language) | Nil)
Specifies recognition language of the document.
-
#letter_set : String | Nil
Specifies the letter set, which should be used during recognition.
-
#letter_set=(letter_set : String | Nil)
Specifies the letter set, which should be used during recognition.
-
#marking_type : FieldMarkingType | Nil
This property is valid only for the handprint recognition.
-
#marking_type=(marking_type : FieldMarkingType | Nil)
This property is valid only for the handprint recognition.
-
#one_text_line : Bool | Nil
Specifies whether the field contains only one text line.
-
#one_text_line=(one_text_line : Bool | Nil)
Specifies whether the field contains only one text line.
-
#one_word_per_text_line : Bool | Nil
Specifies whether the field contains only one word in each text line.
-
#one_word_per_text_line=(one_word_per_text_line : Bool | Nil)
Specifies whether the field contains only one word in each text line.
- #params : Hash(String, String)
-
#pdf_password : String | Nil
Contains a password for accessing password-protected images in PDF format.
-
#pdf_password=(pdf_password : String | Nil)
Contains a password for accessing password-protected images in PDF format.
-
#placeholders_count : Int32 | Nil
Specifies the number of character cells for the field.
-
#placeholders_count=(placeholders_count : Int32 | Nil)
Specifies the number of character cells for the field.
-
#reg_exp : String | Nil
Specifies the regular expression which defines which words are allowed in the field and which are not.
-
#reg_exp=(reg_exp : String | Nil)
Specifies the regular expression which defines which words are allowed in the field and which are not.
-
#region : Region | Nil
Specifies the region of the text field on the image.
-
#region=(region : Region | Nil)
Specifies the region of the text field on the image.
- #region=(coordinates : Array(Int32))
-
#text_type : TextType | Array(TextType) | Nil
Specifies the type of the text on a page.
- #text_type=(text_type : TextType | Array(TextType) | Nil)
-
#writing_style : WritingStyle | Nil
Provides additional information about handprinted letters writing style.
-
#writing_style=(writing_style : WritingStyle | Nil)
Provides additional information about handprinted letters writing style.
Instance methods inherited from module Abbyy::Models::FileBody
body : HTTP::Client::BodyType
body,
file_path : String
file_path,
file_path=(file_path : String)
file_path=
Constructor methods inherited from module Abbyy::Models::FileBody
new(file_path : String)
new
Instance methods inherited from class Abbyy::Models::BaseRequest
body : HTTP::Client::BodyType
body,
params : Hash(String, String)
params
Constructor Detail
Instance Method Detail
Contains the description of the processing task. Cannot contain more than 255 characters.
This parameter is not required.
Specifies recognition language of the document. This parameter can contain one language or several languages in an array, for example:
request.language = Language::Spanish
# or
request.language = [
Language::English,
Language::French,
Language::German,
]
See the list of available recognition languages.
Note that not all languages are available for handprint recognition. The languages which are available for handprint recognition are marked with a special comment.
This parameter is not required.
Default value is Language::English.
Specifies recognition language of the document. This parameter can contain one language or several languages in an array, for example:
request.language = Language::Spanish
# or
request.language = [
Language::English,
Language::French,
Language::German,
]
See the list of available recognition languages.
Note that not all languages are available for handprint recognition. The languages which are available for handprint recognition are marked with a special comment.
This parameter is not required.
Default value is Language::English.
Specifies the letter set, which should be used during recognition.
Contains a string with the letter set characters. For example,
"ABCDabcd'-.". By default, the letter set of the language, specified in
the language parameter, is used.
This parameter is not required.
Specifies the letter set, which should be used during recognition.
Contains a string with the letter set characters. For example,
"ABCDabcd'-.". By default, the letter set of the language, specified in
the language parameter, is used.
This parameter is not required.
This property is valid only for the handprint recognition. Specifies the type of marking around letters (for example, underline, frame, box, etc.). By default, there is no marking around letters. The value can be one of the following:
FieldMarkingType::SimpleTextFieldMarkingType::UnderlinedTextFieldMarkingType::TextInFrameFieldMarkingType::GreyBoxesFieldMarkingType::CharBoxSeriesFieldMarkingType::SimpleCombFieldMarkingType::CombInFrameFieldMarkingType::PartitionedFrame
Note: For correct handprint recognition specify the value of the
#placeholders_count parameter.
This parameter is not required.
Default value is FieldMarkingType::SimpleText.
This property is valid only for the handprint recognition. Specifies the type of marking around letters (for example, underline, frame, box, etc.). By default, there is no marking around letters. The value can be one of the following:
FieldMarkingType::SimpleTextFieldMarkingType::UnderlinedTextFieldMarkingType::TextInFrameFieldMarkingType::GreyBoxesFieldMarkingType::CharBoxSeriesFieldMarkingType::SimpleCombFieldMarkingType::CombInFrameFieldMarkingType::PartitionedFrame
Note: For correct handprint recognition specify the value of the
#placeholders_count parameter.
This parameter is not required.
Default value is FieldMarkingType::SimpleText.
Specifies whether the field contains only one text line. The value should be true, if there is one text line in the field; otherwise it should be false.
This parameter is not required.
Default value is false.
Specifies whether the field contains only one text line. The value should be true, if there is one text line in the field; otherwise it should be false.
This parameter is not required.
Default value is false.
Specifies whether the field contains only one word in each text line. The value should be true, if no text line contains more than one word (so the lines of text will be recognized as a single word); otherwise it should be false.
This parameter is not required.
Default value is false.
Specifies whether the field contains only one word in each text line. The value should be true, if no text line contains more than one word (so the lines of text will be recognized as a single word); otherwise it should be false.
This parameter is not required.
Default value is false.
Contains a password for accessing password-protected images in PDF format.
This parameter is not required.
Contains a password for accessing password-protected images in PDF format.
This parameter is not required.
Specifies the number of character cells for the field.
This property has a sense only for the field marking types
(the #marking_type parameter) that imply splitting the text in cells.
Default value for this property is 1, but you should set the appropriate
value to recognize the text correctly.
#placeholders_count parameter.
This parameter is not required.
Specifies the number of character cells for the field.
This property has a sense only for the field marking types
(the #marking_type parameter) that imply splitting the text in cells.
Default value for this property is 1, but you should set the appropriate
value to recognize the text correctly.
#placeholders_count parameter.
This parameter is not required.
Specifies the regular expression which defines which words are allowed in
the field and which are not. See the description of
regular expressions.
By default, the set of allowed words is defined by the dictionary of the
language, specified in the #language parameter.
Note that regular expressions do not strictly limit the set of characters
of the output result, i.e. the recognized value may contain characters
which are not included into the regular expression. During recognition all
hypotheses of a word recognition are checked against the specified regular
expression. If a given recognition variant conforms to the expression, it
has higher probability of being selected as final recognition output. But
if there is no variant that matches regular expression, the result will
not conform to the expression. If you want to limit the set of characters,
which can be recognized, the best way to do it is to use letterSet parameter.
This parameter is not required.
Specifies the regular expression which defines which words are allowed in
the field and which are not. See the description of
regular expressions.
By default, the set of allowed words is defined by the dictionary of the
language, specified in the #language parameter.
Note that regular expressions do not strictly limit the set of characters
of the output result, i.e. the recognized value may contain characters
which are not included into the regular expression. During recognition all
hypotheses of a word recognition are checked against the specified regular
expression. If a given recognition variant conforms to the expression, it
has higher probability of being selected as final recognition output. But
if there is no variant that matches regular expression, the result will
not conform to the expression. If you want to limit the set of characters,
which can be recognized, the best way to do it is to use letterSet parameter.
This parameter is not required.
Specifies the region of the text field on the image. The coordinates of the region are measured in pixels relative to the left top corner of the image and are specified in the following order: left, top, right, bottom. By default, the region of the whole image is used.
This parameter is not required.
Default value is Region.new(-1, -1, -1, -1).
Specifies the region of the text field on the image. The coordinates of the region are measured in pixels relative to the left top corner of the image and are specified in the following order: left, top, right, bottom. By default, the region of the whole image is used.
This parameter is not required.
Default value is Region.new(-1, -1, -1, -1).
Specifies the type of the text on a page. This parameter may also contain several text types in an array, for example:
[TextType::Normal, TextType::Matrix]
The following values can be used:
- TextType::Normal
- TextType::Typewriter
- TextType::Matrix
- TextType::Index
- TextType::OcrA
- TextType::OcrB
- TextType::E13b
- TextType::Cmc7
- TextType::Gothic
This parameter is not required.
Default value is TextType::Normal.
Provides additional information about handprinted letters writing style.
This parameter is not required.
Default value is WritingStyle::Default.
Provides additional information about handprinted letters writing style.
This parameter is not required.
Default value is WritingStyle::Default.