Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members  

ObjectTable Class Reference

Couple (object_id, pointer_to_object). More...

#include <objectTable.h>

Inheritance diagram for ObjectTable::

LI1 ListItem RefCount List of all members.

Public Methods

 ObjectTable (jint i, IdObject *o)
 Constructor. More...

virtual ~ObjectTable ()
 Destructor.

const jint & getKey (jint &key)
 Retrieves object's key. More...

int operator== (const jint &key)
 Compares object with given key. More...

void * operator new (size_t sz)
 Overloaded new() operator.

void operator delete (void *unit)
 Overloaded delete() operator.


Static Public Methods

int hashKey (const jint &key)
 Hash function. More...


Public Attributes

jint id
 unique ID.

IdObjectobj
 pointer to object.


Static Private Attributes

Allocator _allocator
 allocator.


Detailed Description

Couple (object_id, pointer_to_object).

This class consists of two items: unique ID of the object in profiler library's memory (having information about corresponding Java object) and pointer to this object. ID is used during the communication between Java and C++ part of Java profiler, ID uniquely identifies the object - pointers to objects cannot be transfered between Java and C++ - profiled JVM can be run on various platforms with various pointer length and/or on different machine than IDE, too. So, that's why "jint" IDs are used and later transformed to pointers by the profiler library.

See also:
Counter, IdObject
Author:
Marek Przeczek

Definition at line 57 of file objectTable.h.


Constructor & Destructor Documentation

ObjectTable::ObjectTable jint    i,
IdObject   o
[inline]
 

Constructor.

It initializes member variables.

Parameters:
i  ID
o  pointer to object

Definition at line 73 of file objectTable.h.


Member Function Documentation

const jint& ObjectTable::getKey jint &    key [inline]
 

Retrieves object's key.

Parameters:
key  where to store the key
Returns:
key
See also:
Hash

Definition at line 91 of file objectTable.h.

int ObjectTable::hashKey const jint &    key [inline, static]
 

Hash function.

Parameters:
key  reference to a key
Returns:
hash value

Definition at line 110 of file objectTable.h.

int ObjectTable::operator== const jint &    key [inline]
 

Compares object with given key.

Parameters:
key  key
Returns:
1 (true); 0 (false)
See also:
Hash

Definition at line 102 of file objectTable.h.


The documentation for this class was generated from the following files:
Generated on Mon Jan 28 14:53:29 2002 for Java Profiler Dynamic Library by doxygen1.2.11.1 written by Dimitri van Heesch, © 1997-2001