Class: Rafflesia::StructureAlignData

Inherits:
Types::BaseModel
  • Object
show all
Defined in:
lib/rafflesia/proteins/structure_align_data.rb

Constant Summary collapse

HASH_ATTRS =
{
  alignment: :alignment,
  alignment_object_id: :alignment_object_id,
  backend: :backend,
  command: :command,
  executed: :executed,
  query_id: :query_id,
  target_id: :target_id
}.freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(json) ⇒ StructureAlignData

Returns a new instance of StructureAlignData.



27
28
29
30
31
32
33
34
35
36
37
# File 'lib/rafflesia/proteins/structure_align_data.rb', line 27

def initialize(json)
  super()
  hash = self.class.normalize(json)
  @alignment = hash[:alignment] ? Rafflesia::StructureAlignment.new(hash[:alignment]) : nil
  @alignment_object_id = hash[:alignment_object_id]
  @backend = hash[:backend]
  @command = (hash[:command] || [])
  @executed = hash[:executed]
  @query_id = hash[:query_id]
  @target_id = hash[:target_id]
end

Instance Attribute Details

#alignmentObject

Returns the value of attribute alignment.



18
19
20
# File 'lib/rafflesia/proteins/structure_align_data.rb', line 18

def alignment
  @alignment
end

#alignment_object_idObject

Returns the value of attribute alignment_object_id.



18
19
20
# File 'lib/rafflesia/proteins/structure_align_data.rb', line 18

def alignment_object_id
  @alignment_object_id
end

#backendObject

Returns the value of attribute backend.



18
19
20
# File 'lib/rafflesia/proteins/structure_align_data.rb', line 18

def backend
  @backend
end

#commandObject

Returns the value of attribute command.



18
19
20
# File 'lib/rafflesia/proteins/structure_align_data.rb', line 18

def command
  @command
end

#executedObject

Returns the value of attribute executed.



18
19
20
# File 'lib/rafflesia/proteins/structure_align_data.rb', line 18

def executed
  @executed
end

#query_idObject

Returns the value of attribute query_id.



18
19
20
# File 'lib/rafflesia/proteins/structure_align_data.rb', line 18

def query_id
  @query_id
end

#target_idObject

Returns the value of attribute target_id.



18
19
20
# File 'lib/rafflesia/proteins/structure_align_data.rb', line 18

def target_id
  @target_id
end