Sha256: 25be68a41c9c8782542b56e35b7fd473f0ba09d670bef6bcdb8170e2655e0778
Contents?: true
Size: 472 Bytes
Versions: 1
Compression:
Stored size: 472 Bytes
Contents
class Cell attr_reader :cellId, :objectId def initialize(app,cellId) @cellId=cellId @app=app @data=nil @objectId=nil tryRead end def save(object) @objectId=object.objectId @data=LocalObjectStorage::Marshal::dump(object) saveIntern self end def load LocalObjectStorage::Marshal::load(@data,@app) end private def saveIntern @app.store[@cellId]=@data end def tryRead @data=@app.store[@cellId] end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
appswarm-0.0.1 | apps/local_object_storage/lib/cell.rb |