Class: Rafflesia::DatasetBuildTableSummary

Inherits:
Types::BaseModel
  • Object
show all
Defined in:
lib/rafflesia/datasets/dataset_build_table_summary.rb

Constant Summary collapse

HASH_ATTRS =
{
  row_count: :row_count,
  schema_hashes: :schema_hashes,
  structure_count: :structure_count,
  table_artifact_count: :table_artifact_count,
  table_name: :table_name
}.freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(json) ⇒ DatasetBuildTableSummary

Returns a new instance of DatasetBuildTableSummary.



23
24
25
26
27
28
29
30
31
# File 'lib/rafflesia/datasets/dataset_build_table_summary.rb', line 23

def initialize(json)
  super()
  hash = self.class.normalize(json)
  @row_count = hash[:row_count]
  @schema_hashes = (hash[:schema_hashes] || [])
  @structure_count = hash[:structure_count]
  @table_artifact_count = hash[:table_artifact_count]
  @table_name = hash[:table_name]
end

Instance Attribute Details

#row_countObject

Returns the value of attribute row_count.



16
17
18
# File 'lib/rafflesia/datasets/dataset_build_table_summary.rb', line 16

def row_count
  @row_count
end

#schema_hashesObject

Returns the value of attribute schema_hashes.



16
17
18
# File 'lib/rafflesia/datasets/dataset_build_table_summary.rb', line 16

def schema_hashes
  @schema_hashes
end

#structure_countObject

Returns the value of attribute structure_count.



16
17
18
# File 'lib/rafflesia/datasets/dataset_build_table_summary.rb', line 16

def structure_count
  @structure_count
end

#table_artifact_countObject

Returns the value of attribute table_artifact_count.



16
17
18
# File 'lib/rafflesia/datasets/dataset_build_table_summary.rb', line 16

def table_artifact_count
  @table_artifact_count
end

#table_nameObject

Returns the value of attribute table_name.



16
17
18
# File 'lib/rafflesia/datasets/dataset_build_table_summary.rb', line 16

def table_name
  @table_name
end