Class: Rafflesia::SearchSegmentPlanData
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- Rafflesia::SearchSegmentPlanData
- Defined in:
- lib/rafflesia/proteins/search_segment_plan_data.rb
Constant Summary collapse
- HASH_ATTRS =
{ block_count: :block_count, budget: :budget, key_mode: :key_mode, manifest_object_id: :manifest_object_id, payload_selection: :payload_selection, planned_materialized_bytes: :planned_materialized_bytes, planned_object_bytes: :planned_object_bytes, planned_object_read_count: :planned_object_read_count, query_key: :query_key, reads: :reads, root_object_id: :root_object_id, segment_id: :segment_id, selected_block_count: :selected_block_count }.freeze
Instance Attribute Summary collapse
-
#block_count ⇒ Object
Returns the value of attribute block_count.
-
#budget ⇒ Object
Returns the value of attribute budget.
-
#key_mode ⇒ Object
Returns the value of attribute key_mode.
-
#manifest_object_id ⇒ Object
Returns the value of attribute manifest_object_id.
-
#payload_selection ⇒ Object
Returns the value of attribute payload_selection.
-
#planned_materialized_bytes ⇒ Object
Returns the value of attribute planned_materialized_bytes.
-
#planned_object_bytes ⇒ Object
Returns the value of attribute planned_object_bytes.
-
#planned_object_read_count ⇒ Object
Returns the value of attribute planned_object_read_count.
-
#query_key ⇒ Object
Returns the value of attribute query_key.
-
#reads ⇒ Object
Returns the value of attribute reads.
-
#root_object_id ⇒ Object
Returns the value of attribute root_object_id.
-
#segment_id ⇒ Object
Returns the value of attribute segment_id.
-
#selected_block_count ⇒ Object
Returns the value of attribute selected_block_count.
Instance Method Summary collapse
-
#initialize(json) ⇒ SearchSegmentPlanData
constructor
A new instance of SearchSegmentPlanData.
Constructor Details
#initialize(json) ⇒ SearchSegmentPlanData
Returns a new instance of SearchSegmentPlanData.
39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 |
# File 'lib/rafflesia/proteins/search_segment_plan_data.rb', line 39 def initialize(json) super() hash = self.class.normalize(json) @block_count = hash[:block_count] @budget = hash[:budget] ? Rafflesia::SearchPhysicalPlanBudget.new(hash[:budget]) : nil @key_mode = hash[:key_mode] @manifest_object_id = hash[:manifest_object_id] @payload_selection = hash[:payload_selection] @planned_materialized_bytes = hash[:planned_materialized_bytes] @planned_object_bytes = hash[:planned_object_bytes] @planned_object_read_count = hash[:planned_object_read_count] @query_key = hash[:query_key] @reads = (hash[:reads] || []).map { |item| item ? Rafflesia::SearchSegmentObjectReadPlan.new(item) : nil } @root_object_id = hash[:root_object_id] @segment_id = hash[:segment_id] @selected_block_count = hash[:selected_block_count] end |
Instance Attribute Details
#block_count ⇒ Object
Returns the value of attribute block_count.
24 25 26 |
# File 'lib/rafflesia/proteins/search_segment_plan_data.rb', line 24 def block_count @block_count end |
#budget ⇒ Object
Returns the value of attribute budget.
24 25 26 |
# File 'lib/rafflesia/proteins/search_segment_plan_data.rb', line 24 def budget @budget end |
#key_mode ⇒ Object
Returns the value of attribute key_mode.
24 25 26 |
# File 'lib/rafflesia/proteins/search_segment_plan_data.rb', line 24 def key_mode @key_mode end |
#manifest_object_id ⇒ Object
Returns the value of attribute manifest_object_id.
24 25 26 |
# File 'lib/rafflesia/proteins/search_segment_plan_data.rb', line 24 def manifest_object_id @manifest_object_id end |
#payload_selection ⇒ Object
Returns the value of attribute payload_selection.
24 25 26 |
# File 'lib/rafflesia/proteins/search_segment_plan_data.rb', line 24 def payload_selection @payload_selection end |
#planned_materialized_bytes ⇒ Object
Returns the value of attribute planned_materialized_bytes.
24 25 26 |
# File 'lib/rafflesia/proteins/search_segment_plan_data.rb', line 24 def planned_materialized_bytes @planned_materialized_bytes end |
#planned_object_bytes ⇒ Object
Returns the value of attribute planned_object_bytes.
24 25 26 |
# File 'lib/rafflesia/proteins/search_segment_plan_data.rb', line 24 def planned_object_bytes @planned_object_bytes end |
#planned_object_read_count ⇒ Object
Returns the value of attribute planned_object_read_count.
24 25 26 |
# File 'lib/rafflesia/proteins/search_segment_plan_data.rb', line 24 def planned_object_read_count @planned_object_read_count end |
#query_key ⇒ Object
Returns the value of attribute query_key.
24 25 26 |
# File 'lib/rafflesia/proteins/search_segment_plan_data.rb', line 24 def query_key @query_key end |
#reads ⇒ Object
Returns the value of attribute reads.
24 25 26 |
# File 'lib/rafflesia/proteins/search_segment_plan_data.rb', line 24 def reads @reads end |
#root_object_id ⇒ Object
Returns the value of attribute root_object_id.
24 25 26 |
# File 'lib/rafflesia/proteins/search_segment_plan_data.rb', line 24 def root_object_id @root_object_id end |
#segment_id ⇒ Object
Returns the value of attribute segment_id.
24 25 26 |
# File 'lib/rafflesia/proteins/search_segment_plan_data.rb', line 24 def segment_id @segment_id end |
#selected_block_count ⇒ Object
Returns the value of attribute selected_block_count.
24 25 26 |
# File 'lib/rafflesia/proteins/search_segment_plan_data.rb', line 24 def selected_block_count @selected_block_count end |