Class: Rafflesia::MoleculeNormalizeData
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- Rafflesia::MoleculeNormalizeData
- Defined in:
- lib/rafflesia/molecules/molecule_normalize_data.rb
Constant Summary collapse
- HASH_ATTRS =
{ backend: :backend, canonical_smiles: :canonical_smiles, inchikey: :inchikey, molecule_id: :molecule_id }.freeze
Instance Attribute Summary collapse
-
#backend ⇒ Object
Returns the value of attribute backend.
-
#canonical_smiles ⇒ Object
Returns the value of attribute canonical_smiles.
-
#inchikey ⇒ Object
Returns the value of attribute inchikey.
-
#molecule_id ⇒ Object
Returns the value of attribute molecule_id.
Instance Method Summary collapse
-
#initialize(json) ⇒ MoleculeNormalizeData
constructor
A new instance of MoleculeNormalizeData.
Constructor Details
#initialize(json) ⇒ MoleculeNormalizeData
Returns a new instance of MoleculeNormalizeData.
21 22 23 24 25 26 27 28 |
# File 'lib/rafflesia/molecules/molecule_normalize_data.rb', line 21 def initialize(json) super() hash = self.class.normalize(json) @backend = hash[:backend] @canonical_smiles = hash[:canonical_smiles] @inchikey = hash[:inchikey] @molecule_id = hash[:molecule_id] end |
Instance Attribute Details
#backend ⇒ Object
Returns the value of attribute backend.
15 16 17 |
# File 'lib/rafflesia/molecules/molecule_normalize_data.rb', line 15 def backend @backend end |
#canonical_smiles ⇒ Object
Returns the value of attribute canonical_smiles.
15 16 17 |
# File 'lib/rafflesia/molecules/molecule_normalize_data.rb', line 15 def canonical_smiles @canonical_smiles end |
#inchikey ⇒ Object
Returns the value of attribute inchikey.
15 16 17 |
# File 'lib/rafflesia/molecules/molecule_normalize_data.rb', line 15 def inchikey @inchikey end |
#molecule_id ⇒ Object
Returns the value of attribute molecule_id.
15 16 17 |
# File 'lib/rafflesia/molecules/molecule_normalize_data.rb', line 15 def molecule_id @molecule_id end |