Class: TencentCloud::Ocr::V20181119::TextDetectionResult

Inherits:
Common::AbstractModel
  • Object
show all
Defined in:
lib/v20181119/models.rb

Overview

识别结果

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(value = nil, polygon = nil) ⇒ TextDetectionResult

Returns a new instance of TextDetectionResult.



11906
11907
11908
11909
# File 'lib/v20181119/models.rb', line 11906

def initialize(value=nil, polygon=nil)
  @Value = value
  @Polygon = polygon
end

Instance Attribute Details

#PolygonObject

Parameters:

  • Value:

    识别出的文本行内容

  • Polygon:

    坐标,以四个顶点坐标表示



11904
11905
11906
# File 'lib/v20181119/models.rb', line 11904

def Polygon
  @Polygon
end

#ValueObject

Parameters:

  • Value:

    识别出的文本行内容

  • Polygon:

    坐标,以四个顶点坐标表示



11904
11905
11906
# File 'lib/v20181119/models.rb', line 11904

def Value
  @Value
end

Instance Method Details

#deserialize(params) ⇒ Object



11911
11912
11913
11914
11915
11916
11917
11918
11919
11920
11921
# File 'lib/v20181119/models.rb', line 11911

def deserialize(params)
  @Value = params['Value']
  unless params['Polygon'].nil?
    @Polygon = []
    params['Polygon'].each do |i|
      coord_tmp = Coord.new
      coord_tmp.deserialize(i)
      @Polygon << coord_tmp
    end
  end
end