Class: Rafflesia::SequenceAlignRequest

Inherits:
Types::BaseModel
  • Object
show all
Defined in:
lib/rafflesia/sequences/sequence_align_request.rb

Constant Summary collapse

HASH_ATTRS =
{
  gap: :gap,
  match: :match,
  mismatch: :mismatch,
  query: :query,
  query_positions: :query_positions,
  target: :target
}.freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(json) ⇒ SequenceAlignRequest

Returns a new instance of SequenceAlignRequest.



25
26
27
28
29
30
31
32
33
34
# File 'lib/rafflesia/sequences/sequence_align_request.rb', line 25

def initialize(json)
  super()
  hash = self.class.normalize(json)
  @gap = hash[:gap]
  @match = hash[:match]
  @mismatch = hash[:mismatch]
  @query = hash[:query]
  @query_positions = (hash[:query_positions] || [])
  @target = hash[:target]
end

Instance Attribute Details

#gapObject

Returns the value of attribute gap.



17
18
19
# File 'lib/rafflesia/sequences/sequence_align_request.rb', line 17

def gap
  @gap
end

#matchObject

Returns the value of attribute match.



17
18
19
# File 'lib/rafflesia/sequences/sequence_align_request.rb', line 17

def match
  @match
end

#mismatchObject

Returns the value of attribute mismatch.



17
18
19
# File 'lib/rafflesia/sequences/sequence_align_request.rb', line 17

def mismatch
  @mismatch
end

#queryObject

Returns the value of attribute query.



17
18
19
# File 'lib/rafflesia/sequences/sequence_align_request.rb', line 17

def query
  @query
end

#query_positionsObject

Returns the value of attribute query_positions.



17
18
19
# File 'lib/rafflesia/sequences/sequence_align_request.rb', line 17

def query_positions
  @query_positions
end

#targetObject

Returns the value of attribute target.



17
18
19
# File 'lib/rafflesia/sequences/sequence_align_request.rb', line 17

def target
  @target
end