Class: Rafflesia::PocketLigandDistancesRequest

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

Constant Summary collapse

HASH_ATTRS =
{
  database: :database,
  distance_threshold_angstrom: :distance_threshold_angstrom,
  include_waters: :include_waters,
  ligand_grouping: :ligand_grouping,
  ligands: :ligands,
  max_pairs: :max_pairs,
  output_format: :output_format,
  output_relation: :output_relation,
  partition_by: :partition_by,
  pockets: :pockets,
  prediction_format: :prediction_format,
  prediction_method: :prediction_method,
  prediction_path: :prediction_path,
  preview_limit: :preview_limit,
  relation: :relation,
  release: :release,
  sort_by: :sort_by,
  structure_id: :structure_id,
  top_extra: :top_extra,
  top_n_reference: :top_n_reference
}.freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(json) ⇒ PocketLigandDistancesRequest

Returns a new instance of PocketLigandDistancesRequest.



53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 53

def initialize(json)
  super()
  hash = self.class.normalize(json)
  @database = hash[:database]
  @distance_threshold_angstrom = hash[:distance_threshold_angstrom]
  @include_waters = hash[:include_waters]
  @ligand_grouping = hash[:ligand_grouping]
  @ligands = (hash[:ligands] || [])
  @max_pairs = hash[:max_pairs]
  @output_format = hash[:output_format]
  @output_relation = hash[:output_relation]
  @partition_by = (hash[:partition_by] || [])
  @pockets = (hash[:pockets] || []).map { |item| item ? Rafflesia::Pocket.new(item) : nil }
  @prediction_format = hash[:prediction_format]
  @prediction_method = hash[:prediction_method]
  @prediction_path = hash[:prediction_path]
  @preview_limit = hash[:preview_limit]
  @relation = hash[:relation]
  @release = hash[:release]
  @sort_by = (hash[:sort_by] || [])
  @structure_id = hash[:structure_id]
  @top_extra = hash[:top_extra]
  @top_n_reference = hash[:top_n_reference]
end

Instance Attribute Details

#databaseObject

Returns the value of attribute database.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def database
  @database
end

#distance_threshold_angstromObject

Returns the value of attribute distance_threshold_angstrom.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def distance_threshold_angstrom
  @distance_threshold_angstrom
end

#include_watersObject

Returns the value of attribute include_waters.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def include_waters
  @include_waters
end

#ligand_groupingObject

Returns the value of attribute ligand_grouping.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def ligand_grouping
  @ligand_grouping
end

#ligandsObject

Returns the value of attribute ligands.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def ligands
  @ligands
end

#max_pairsObject

Returns the value of attribute max_pairs.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def max_pairs
  @max_pairs
end

#output_formatObject

Returns the value of attribute output_format.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def output_format
  @output_format
end

#output_relationObject

Returns the value of attribute output_relation.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def output_relation
  @output_relation
end

#partition_byObject

Returns the value of attribute partition_by.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def partition_by
  @partition_by
end

#pocketsObject

Returns the value of attribute pockets.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def pockets
  @pockets
end

#prediction_formatObject

Returns the value of attribute prediction_format.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def prediction_format
  @prediction_format
end

#prediction_methodObject

Returns the value of attribute prediction_method.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def prediction_method
  @prediction_method
end

#prediction_pathObject

Returns the value of attribute prediction_path.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def prediction_path
  @prediction_path
end

#preview_limitObject

Returns the value of attribute preview_limit.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def preview_limit
  @preview_limit
end

#relationObject

Returns the value of attribute relation.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def relation
  @relation
end

#releaseObject

Returns the value of attribute release.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def release
  @release
end

#sort_byObject

Returns the value of attribute sort_by.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def sort_by
  @sort_by
end

#structure_idObject

Returns the value of attribute structure_id.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def structure_id
  @structure_id
end

#top_extraObject

Returns the value of attribute top_extra.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def top_extra
  @top_extra
end

#top_n_referenceObject

Returns the value of attribute top_n_reference.



31
32
33
# File 'lib/rafflesia/proteins/pocket_ligand_distances_request.rb', line 31

def top_n_reference
  @top_n_reference
end