Class: A

Inherits:
Object
  • Object
show all
Includes:
Singleton
Defined in:
lib/rubysl/singleton/singleton.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Singleton

__init__, #clone, #dup

Instance Attribute Details

#dieObject

Returns the value of attribute die.



255
256
257
# File 'lib/rubysl/singleton/singleton.rb', line 255

def die
  @die
end

#persistObject

Returns the value of attribute persist.



255
256
257
# File 'lib/rubysl/singleton/singleton.rb', line 255

def persist
  @persist
end

Class Method Details

._load(str) ⇒ Object



262
263
264
265
# File 'lib/rubysl/singleton/singleton.rb', line 262

def A._load(str)
  instance.persist = Marshal.load(str)
  instance
end

Instance Method Details

#_dump(depth) ⇒ Object



256
257
258
259
# File 'lib/rubysl/singleton/singleton.rb', line 256

def _dump(depth)
  # this strips the @die information from the instance
  Marshal.dump(@persist,depth)
end