Class: Rafflesia::MmseqSearchData
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- Rafflesia::MmseqSearchData
- Defined in:
- lib/rafflesia/sequences/mmseq_search_data.rb
Constant Summary collapse
- HASH_ATTRS =
{ backend: :backend, command: :command, dry_run: :dry_run, hit_count: :hit_count, hits: :hits, manifest_id: :manifest_id, materialization: :materialization, output_object: :output_object, output_path: :output_path, parameters: :parameters, query: :query, raw_output_object: :raw_output_object, relation: :relation, target: :target }.freeze
Instance Attribute Summary collapse
-
#backend ⇒ Object
Returns the value of attribute backend.
-
#command ⇒ Object
Returns the value of attribute command.
-
#dry_run ⇒ Object
Returns the value of attribute dry_run.
-
#hit_count ⇒ Object
Returns the value of attribute hit_count.
-
#hits ⇒ Object
Returns the value of attribute hits.
-
#manifest_id ⇒ Object
Returns the value of attribute manifest_id.
-
#materialization ⇒ Object
Returns the value of attribute materialization.
-
#output_object ⇒ Object
Returns the value of attribute output_object.
-
#output_path ⇒ Object
Returns the value of attribute output_path.
-
#parameters ⇒ Object
Returns the value of attribute parameters.
-
#query ⇒ Object
Returns the value of attribute query.
-
#raw_output_object ⇒ Object
Returns the value of attribute raw_output_object.
-
#relation ⇒ Object
Returns the value of attribute relation.
-
#target ⇒ Object
Returns the value of attribute target.
Instance Method Summary collapse
-
#initialize(json) ⇒ MmseqSearchData
constructor
A new instance of MmseqSearchData.
Constructor Details
#initialize(json) ⇒ MmseqSearchData
Returns a new instance of MmseqSearchData.
41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 |
# File 'lib/rafflesia/sequences/mmseq_search_data.rb', line 41 def initialize(json) super() hash = self.class.normalize(json) @backend = hash[:backend] @command = (hash[:command] || []) @dry_run = hash[:dry_run] @hit_count = hash[:hit_count] @hits = (hash[:hits] || []).map { |item| item ? Rafflesia::MmseqSearchHit.new(item) : nil } @manifest_id = hash[:manifest_id] @materialization = hash[:materialization] ? Rafflesia::ObjectArtifactMaterializeData.new(hash[:materialization]) : nil @output_object = hash[:output_object] ? Rafflesia::ObjectRef.new(hash[:output_object]) : nil @output_path = hash[:output_path] @parameters = hash[:parameters] || {} @query = hash[:query] @raw_output_object = hash[:raw_output_object] ? Rafflesia::ObjectRef.new(hash[:raw_output_object]) : nil @relation = hash[:relation] ? Rafflesia::RelationArtifactData.new(hash[:relation]) : nil @target = hash[:target] end |
Instance Attribute Details
#backend ⇒ Object
Returns the value of attribute backend.
25 26 27 |
# File 'lib/rafflesia/sequences/mmseq_search_data.rb', line 25 def backend @backend end |
#command ⇒ Object
Returns the value of attribute command.
25 26 27 |
# File 'lib/rafflesia/sequences/mmseq_search_data.rb', line 25 def command @command end |
#dry_run ⇒ Object
Returns the value of attribute dry_run.
25 26 27 |
# File 'lib/rafflesia/sequences/mmseq_search_data.rb', line 25 def dry_run @dry_run end |
#hit_count ⇒ Object
Returns the value of attribute hit_count.
25 26 27 |
# File 'lib/rafflesia/sequences/mmseq_search_data.rb', line 25 def hit_count @hit_count end |
#hits ⇒ Object
Returns the value of attribute hits.
25 26 27 |
# File 'lib/rafflesia/sequences/mmseq_search_data.rb', line 25 def hits @hits end |
#manifest_id ⇒ Object
Returns the value of attribute manifest_id.
25 26 27 |
# File 'lib/rafflesia/sequences/mmseq_search_data.rb', line 25 def manifest_id @manifest_id end |
#materialization ⇒ Object
Returns the value of attribute materialization.
25 26 27 |
# File 'lib/rafflesia/sequences/mmseq_search_data.rb', line 25 def materialization @materialization end |
#output_object ⇒ Object
Returns the value of attribute output_object.
25 26 27 |
# File 'lib/rafflesia/sequences/mmseq_search_data.rb', line 25 def output_object @output_object end |
#output_path ⇒ Object
Returns the value of attribute output_path.
25 26 27 |
# File 'lib/rafflesia/sequences/mmseq_search_data.rb', line 25 def output_path @output_path end |
#parameters ⇒ Object
Returns the value of attribute parameters.
25 26 27 |
# File 'lib/rafflesia/sequences/mmseq_search_data.rb', line 25 def parameters @parameters end |
#query ⇒ Object
Returns the value of attribute query.
25 26 27 |
# File 'lib/rafflesia/sequences/mmseq_search_data.rb', line 25 def query @query end |
#raw_output_object ⇒ Object
Returns the value of attribute raw_output_object.
25 26 27 |
# File 'lib/rafflesia/sequences/mmseq_search_data.rb', line 25 def raw_output_object @raw_output_object end |
#relation ⇒ Object
Returns the value of attribute relation.
25 26 27 |
# File 'lib/rafflesia/sequences/mmseq_search_data.rb', line 25 def relation @relation end |
#target ⇒ Object
Returns the value of attribute target.
25 26 27 |
# File 'lib/rafflesia/sequences/mmseq_search_data.rb', line 25 def target @target end |