Weak::Key (Class)

In: lib/Borges/Utilities/WeakIdentityKeyHash.rb
Parent: Object

A key for Weak::IdentityKeyHash that holds weakly on its contents.

Methods

by_obj   eql?   get_obj   hash   inspect   make_finalizer   new  

Constants

ID_MAP = {}
  Map from an object to a list of its references
ID_REV_MAP = {}
  Map from a reference to its object

Attributes

internal_id  [R]  The object being weakly held by this key.

Classes and Modules

Class Weak::Key::IdentityKeyHash

Public Class methods

Retrives obj’s WeakKey reference.

Creates a finalizer for the object referenced by internal_id that removes that object from hash.

Create a new WeakKey from orig that will remove itself from +hash+when it is no longer referenced.

Public Instance methods

A WeakKey is equal to other if other has the same internal_id or object_id.

Retrieves an object from its id.

A WeakKey’s hash is the held object’s object_id.

Creates a string that represents the internal state of this object.

[Validate]