Class: Chem::TINKER::TinkerAtom
- Inherits:
-
Object
- Object
- Chem::TINKER::TinkerAtom
- Includes:
- Atom
- Defined in:
- lib/chem/db/tinker.rb
Constant Summary
Constants included from Atom
Instance Attribute Summary collapse
-
#connection ⇒ Object
readonly
Returns the value of attribute connection.
-
#element ⇒ Object
readonly
Returns the value of attribute element.
-
#x ⇒ Object
readonly
Returns the value of attribute x.
-
#y ⇒ Object
readonly
Returns the value of attribute y.
-
#z ⇒ Object
readonly
Returns the value of attribute z.
Attributes included from Atom
#charge, #color, #mass, #v_pos, #visible
Instance Method Summary collapse
-
#initialize(ff, x, y, z, connection) ⇒ TinkerAtom
constructor
A new instance of TinkerAtom.
Methods included from Atom
#atomic_number, #electro_negativity, #natural_bond_order, #to_mdl, #to_sybyl, #weight
Constructor Details
#initialize(ff, x, y, z, connection) ⇒ TinkerAtom
Returns a new instance of TinkerAtom.
17 18 19 20 21 22 23 24 |
# File 'lib/chem/db/tinker.rb', line 17 def initialize ff, x, y, z, connection @x, @y, @z = x.to_f, y.to_f, z.to_f @element = ff[0..0] @connection = [] connection.each do |n| @connection.push(n) end end |
Instance Attribute Details
#connection ⇒ Object (readonly)
Returns the value of attribute connection.
16 17 18 |
# File 'lib/chem/db/tinker.rb', line 16 def connection @connection end |
#element ⇒ Object (readonly)
Returns the value of attribute element.
16 17 18 |
# File 'lib/chem/db/tinker.rb', line 16 def element @element end |
#x ⇒ Object (readonly)
Returns the value of attribute x.
16 17 18 |
# File 'lib/chem/db/tinker.rb', line 16 def x @x end |
#y ⇒ Object (readonly)
Returns the value of attribute y.
16 17 18 |
# File 'lib/chem/db/tinker.rb', line 16 def y @y end |
#z ⇒ Object (readonly)
Returns the value of attribute z.
16 17 18 |
# File 'lib/chem/db/tinker.rb', line 16 def z @z end |