Class: Chem::Sybyl::SybylAtom
- Inherits:
-
Object
- Object
- Chem::Sybyl::SybylAtom
show all
- Includes:
- Atom
- Defined in:
- lib/chem/db/sybyl.rb
Constant Summary
Constants included
from Atom
Atom::MDLAtomLineFormat
Instance Attribute Summary
Attributes included from Atom
#charge, #color, #mass, #v_pos, #visible
Instance Method Summary
collapse
Methods included from Atom
#atomic_number, #electro_negativity, #natural_bond_order, #to_mdl, #to_sybyl, #weight
Constructor Details
#initialize(line) ⇒ SybylAtom
Returns a new instance of SybylAtom.
94
|
# File 'lib/chem/db/sybyl.rb', line 94
def initialize line ; @line = line ; end
|
Instance Method Details
#element ⇒ Object
90
|
# File 'lib/chem/db/sybyl.rb', line 90
def element ; @element ||= @line[53..60].split(".")[0].strip.intern ; end
|
#x ⇒ Object
91
|
# File 'lib/chem/db/sybyl.rb', line 91
def x ; @x ||= @line[16..27].to_f ; end
|
#y ⇒ Object
92
|
# File 'lib/chem/db/sybyl.rb', line 92
def y ; @y ||= @line[28..39].to_f ; end
|
#z ⇒ Object
93
|
# File 'lib/chem/db/sybyl.rb', line 93
def z ; @z ||= @line[40..51].to_f ; end
|