class Chem::Templates::Atom

Defined in:

chem/templates/atom.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(name : String, element : Element, bonded_elements : Array(Element), formal_charge : Int32 = 0, valence : Int32 | Nil = nil) #

[View source]
def self.new(name : String, top_spec : String, formal_charge : Int32 = 0, valence : Int32 | Nil = nil) : self #

[View source]

Instance Method Detail

def bonded_elements : Array::View(Element) #

[View source]
def element : Element #

[View source]
def formal_charge : Int32 #

[View source]
def name : String #

[View source]
def suffix : String | Nil #

[View source]
def to_s(io : IO) #
Description copied from class Reference

Appends a short String representation of this object which includes its class name and its object address.

class Person
  def initialize(@name : String, @age : Int32)
  end
end

Person.new("John", 32).to_s # => #<Person:0x10a199f20>

[View source]
def top_spec : String #

[View source]
def valence : Int32 | Nil #

[View source]