Class: TencentCloud::Ocr::V20181119::TableDetectInfo

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

Overview

表格内容检测

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(cells = nil, titles = nil, type = nil, tablecoordpoint = nil) ⇒ TableDetectInfo

Returns a new instance of TableDetectInfo.



11515
11516
11517
11518
11519
11520
# File 'lib/v20181119/models.rb', line 11515

def initialize(cells=nil, titles=nil, type=nil, tablecoordpoint=nil)
  @Cells = cells
  @Titles = titles
  @Type = type
  @TableCoordPoint = tablecoordpoint
end

Instance Attribute Details

#CellsObject

注意:此字段可能返回 null,表示取不到有效值。 注意:此字段可能返回 null,表示取不到有效值。 1 为有线表格,2 为无线表格 (接口暂不支持日文无线表格识别,若传入日文无线表格,返回0) 注意:此字段可能返回 null,表示取不到有效值。 右上角,右下角,左下角) 注意:此字段可能返回 null,表示取不到有效值。

Parameters:

  • Cells:

    单元格内容

  • Titles:

    表格标题

  • Type:

    图像中的文本块类型,0 为非表格文本,

  • TableCoordPoint:

    表格主体四个顶点坐标(依次为左上角,



11513
11514
11515
# File 'lib/v20181119/models.rb', line 11513

def Cells
  @Cells
end

#TableCoordPointObject

注意:此字段可能返回 null,表示取不到有效值。 注意:此字段可能返回 null,表示取不到有效值。 1 为有线表格,2 为无线表格 (接口暂不支持日文无线表格识别,若传入日文无线表格,返回0) 注意:此字段可能返回 null,表示取不到有效值。 右上角,右下角,左下角) 注意:此字段可能返回 null,表示取不到有效值。

Parameters:

  • Cells:

    单元格内容

  • Titles:

    表格标题

  • Type:

    图像中的文本块类型,0 为非表格文本,

  • TableCoordPoint:

    表格主体四个顶点坐标(依次为左上角,



11513
11514
11515
# File 'lib/v20181119/models.rb', line 11513

def TableCoordPoint
  @TableCoordPoint
end

#TitlesObject

注意:此字段可能返回 null,表示取不到有效值。 注意:此字段可能返回 null,表示取不到有效值。 1 为有线表格,2 为无线表格 (接口暂不支持日文无线表格识别,若传入日文无线表格,返回0) 注意:此字段可能返回 null,表示取不到有效值。 右上角,右下角,左下角) 注意:此字段可能返回 null,表示取不到有效值。

Parameters:

  • Cells:

    单元格内容

  • Titles:

    表格标题

  • Type:

    图像中的文本块类型,0 为非表格文本,

  • TableCoordPoint:

    表格主体四个顶点坐标(依次为左上角,



11513
11514
11515
# File 'lib/v20181119/models.rb', line 11513

def Titles
  @Titles
end

#TypeObject

注意:此字段可能返回 null,表示取不到有效值。 注意:此字段可能返回 null,表示取不到有效值。 1 为有线表格,2 为无线表格 (接口暂不支持日文无线表格识别,若传入日文无线表格,返回0) 注意:此字段可能返回 null,表示取不到有效值。 右上角,右下角,左下角) 注意:此字段可能返回 null,表示取不到有效值。

Parameters:

  • Cells:

    单元格内容

  • Titles:

    表格标题

  • Type:

    图像中的文本块类型,0 为非表格文本,

  • TableCoordPoint:

    表格主体四个顶点坐标(依次为左上角,



11513
11514
11515
# File 'lib/v20181119/models.rb', line 11513

def Type
  @Type
end

Instance Method Details

#deserialize(params) ⇒ Object



11522
11523
11524
11525
11526
11527
11528
11529
11530
11531
11532
11533
11534
11535
11536
11537
11538
11539
11540
11541
11542
11543
11544
11545
11546
11547
11548
# File 'lib/v20181119/models.rb', line 11522

def deserialize(params)
  unless params['Cells'].nil?
    @Cells = []
    params['Cells'].each do |i|
      tablecell_tmp = TableCell.new
      tablecell_tmp.deserialize(i)
      @Cells << tablecell_tmp
    end
  end
  unless params['Titles'].nil?
    @Titles = []
    params['Titles'].each do |i|
      tabletitle_tmp = TableTitle.new
      tabletitle_tmp.deserialize(i)
      @Titles << tabletitle_tmp
    end
  end
  @Type = params['Type']
  unless params['TableCoordPoint'].nil?
    @TableCoordPoint = []
    params['TableCoordPoint'].each do |i|
      coord_tmp = Coord.new
      coord_tmp.deserialize(i)
      @TableCoordPoint << coord_tmp
    end
  end
end