class Upl::Inter::Agc

keep track of object_id atoms that were assigned in prolog, and prolog now wants to garbage collect them.

Public Class Methods

instance() click to toggle source
# File lib/upl/inter.rb, line 56
def self.instance
  @instance ||= new
end
new() click to toggle source
# File lib/upl/inter.rb, line 52
def initialize
  @id_objects = {}
end

Public Instance Methods

deregister(obj) click to toggle source
# File lib/upl/inter.rb, line 64
def deregister obj
  @id_objects.delete obj.object_id
end
register(obj) click to toggle source
# File lib/upl/inter.rb, line 60
def register obj
  @id_objects[obj.object_id] = obj
end