Class: Google::Cloud::Vision::Annotation::Text::Page::Language
- Inherits:
-
Object
- Object
- Google::Cloud::Vision::Annotation::Text::Page::Language
- Defined in:
- lib/google/cloud/vision/annotation/text.rb
Overview
Language
A language within a detected text (OCR). See Google::Cloud::Vision::Annotation::Text#pages.
Instance Method Summary collapse
-
#code ⇒ String
The language code detected for a structural component.
-
#confidence ⇒ Float
Confidence of detected language.
-
#to_h ⇒ Hash
Deeply converts object to a hash.
Instance Method Details
#code ⇒ String
The language code detected for a structural component.
971 972 973 |
# File 'lib/google/cloud/vision/annotation/text.rb', line 971 def code @grpc.language_code end |
#confidence ⇒ Float
Confidence of detected language.
980 981 982 |
# File 'lib/google/cloud/vision/annotation/text.rb', line 980 def confidence @grpc.confidence end |
#to_h ⇒ Hash
Deeply converts object to a hash. All keys will be symbolized.
989 990 991 |
# File 'lib/google/cloud/vision/annotation/text.rb', line 989 def to_h { code: code, confidence: confidence } end |