adaptj.event
Class ClassLoadEvent

java.lang.Object
  |
  +--adaptj.event.AdaptJEvent
        |
        +--adaptj.event.ClassLoadEvent
All Implemented Interfaces:
AdaptJSpecConstants, ClassEvent

public class ClassLoadEvent
extends AdaptJEvent
implements ClassEvent

An Event corresponding to the JVMPI_CLASS_LOAD event. This event is triggered when a class is loaded by the Java VM.

Author:
Bruno Dufour
See Also:
ClassUnloadEvent, The Java Virtual Machine Profiler Interface (JVMPI)

Field Summary
 
Fields inherited from class adaptj.event.AdaptJEvent
ADAPTJ_ARENA_DELETE, ADAPTJ_ARENA_NEW, ADAPTJ_CLASS_LOAD, ADAPTJ_CLASS_LOAD_HOOK, ADAPTJ_CLASS_UNLOAD, ADAPTJ_COMPILED_METHOD_LOAD, ADAPTJ_COMPILED_METHOD_UNLOAD, ADAPTJ_DATA_DUMP_REQUEST, ADAPTJ_DATA_RESET_REQUEST, ADAPTJ_EVENT_COUNT, ADAPTJ_GC_FINISH, ADAPTJ_GC_START, ADAPTJ_HEAP_DUMP, ADAPTJ_INSTRUCTION_START, ADAPTJ_JNI_GLOBALREF_ALLOC, ADAPTJ_JNI_GLOBALREF_FREE, ADAPTJ_JNI_WEAK_GLOBALREF_ALLOC, ADAPTJ_JNI_WEAK_GLOBALREF_FREE, ADAPTJ_JVM_INIT_DONE, ADAPTJ_JVM_SHUT_DOWN, ADAPTJ_METHOD_ENTRY, ADAPTJ_METHOD_ENTRY2, ADAPTJ_METHOD_EXIT, ADAPTJ_MONITOR_CONTENDED_ENTER, ADAPTJ_MONITOR_CONTENDED_ENTERED, ADAPTJ_MONITOR_CONTENDED_EXIT, ADAPTJ_MONITOR_DUMP, ADAPTJ_MONITOR_WAIT, ADAPTJ_MONITOR_WAITED, ADAPTJ_OBJECT_ALLOC, ADAPTJ_OBJECT_DUMP, ADAPTJ_OBJECT_FREE, ADAPTJ_OBJECT_MOVE, ADAPTJ_RAW_MONITOR_CONTENDED_ENTER, ADAPTJ_RAW_MONITOR_CONTENDED_ENTERED, ADAPTJ_RAW_MONITOR_CONTENDED_EXIT, ADAPTJ_REQUESTED_EVENT, ADAPTJ_THREAD_END, ADAPTJ_THREAD_START, ADAPTJ_THREAD_STATUS_CHANGE, ADAPTJ_UNKNOWN
 
Fields inherited from interface adaptj.spec.AdaptJSpecConstants
ADAPTJ_COMPACT_INSTRUCTION_START, ADAPTJ_FIELD_ARENA_ID, ADAPTJ_FIELD_ARENA_NAME, ADAPTJ_FIELD_CHOSEN_PAIR_INDEX, ADAPTJ_FIELD_CLASS_LOAD_CLASS_ID, ADAPTJ_FIELD_CLASS_NAME, ADAPTJ_FIELD_CLASS_UNLOAD_CLASS_ID, ADAPTJ_FIELD_CODE, ADAPTJ_FIELD_CODE_SIZE, ADAPTJ_FIELD_COUNTED, ADAPTJ_FIELD_DATA, ADAPTJ_FIELD_DATA_LEN, ADAPTJ_FIELD_ENV_ID, ADAPTJ_FIELD_GROUP_NAME, ADAPTJ_FIELD_HI, ADAPTJ_FIELD_ID, ADAPTJ_FIELD_INSTANCES, ADAPTJ_FIELD_IS_ARRAY, ADAPTJ_FIELD_IS_TRUE, ADAPTJ_FIELD_KEY, ADAPTJ_FIELD_LINENO_TABLE, ADAPTJ_FIELD_LINENO_TABLE_SIZE, ADAPTJ_FIELD_LOW, ADAPTJ_FIELD_METHOD_ID, ADAPTJ_FIELD_METHODS, ADAPTJ_FIELD_NAME, ADAPTJ_FIELD_NEW_ARENA_ID, ADAPTJ_FIELD_NEW_OBJ_ID, ADAPTJ_FIELD_NEW_STATUS, ADAPTJ_FIELD_NUM_INSTANCE_FIELDS, ADAPTJ_FIELD_NUM_INTERFACES, ADAPTJ_FIELD_NUM_METHODS, ADAPTJ_FIELD_NUM_STATIC_FIELDS, ADAPTJ_FIELD_NUM_TRACES, ADAPTJ_FIELD_OBJ_ID, ADAPTJ_FIELD_OBJECT, ADAPTJ_FIELD_OBJECT_ALLOC_CLASS_ID, ADAPTJ_FIELD_OFFSET, ADAPTJ_FIELD_PAIRS_TOTAL, ADAPTJ_FIELD_PARENT_NAME, ADAPTJ_FIELD_RECORDED, ADAPTJ_FIELD_REF_ID, ADAPTJ_FIELD_SIZE, ADAPTJ_FIELD_SOURCE_NAME, ADAPTJ_FIELD_STATICS, ADAPTJ_FIELD_THREAD_ENV_ID, ADAPTJ_FIELD_THREAD_ID, ADAPTJ_FIELD_THREAD_NAME, ADAPTJ_FIELD_TIMEOUT, ADAPTJ_FIELD_TOTAL_OBJECT_SPACE, ADAPTJ_FIELD_TRACES, ADAPTJ_FIELD_USED_OBJECT_SPACE, ADAPTJ_FIELD_USED_OBJECTS, ADAPTJ_FILESPLIT, ADAPTJ_ISPIPED, ADAPTJ_MAGIC, ADAPTJ_SPEC_MAGIC, VERSION_MASK
 
Constructor Summary
ClassLoadEvent()
           
ClassLoadEvent(java.lang.String class_name, java.lang.String source_name, int num_interfaces, JVMPIMethod[] methods, JVMPIField[] statics, JVMPIField[] instances, int class_id)
           
 
Method Summary
 int getClassID()
          Get class_id.
 java.lang.String getClassName()
          Get class_name.
 java.lang.String getFullClassName()
          Get fullClassName.
 JVMPIField[] getInstances()
          Get instances.
 JVMPIField getInstances(int index)
          Get instances element at specified index.
 JVMPIMethod getMethod(int index)
          Get methods element at specified index.
 JVMPIMethod[] getMethods()
          Get methods.
 int getNumInstanceFields()
          Get num_instance_fields.
 int getNumInterfaces()
          Get num_interfaces.
 int getNumMethods()
          Get num_methods.
 int getNumStaticFields()
          Get num_static_fields.
 java.lang.String getSourceName()
          Get source_name.
 JVMPIField[] getStatics()
          Get statics.
 JVMPIField getStatics(int index)
          Get statics element at specified index.
 void readFromStream(java.io.DataInput in, short info)
           
 void setClassID(int class_id)
          Set class_id.
 void setClassName(java.lang.String class_name)
          Set class_name.
 void setFullClassName(java.lang.String fullClassName)
          Set fullClassName.
 void setInstances(JVMPIField[] instances)
          Set instances.
 void setInstances(JVMPIField instance, int index)
          Set instances at the specified index.
 void setMethod(JVMPIMethod method, int index)
          Set methods at the specified index.
 void setMethods(JVMPIMethod[] methods)
          Set methods.
 void setNumInterfaces(int num_interfaces)
          Set num_interfaces.
 void setSourceName(java.lang.String source_name)
          Set source_name.
 void setStatics(JVMPIField[] statics)
          Set statics.
 void setStatics(JVMPIField statik, int index)
          Set statics at the specified index.
 
Methods inherited from class adaptj.event.AdaptJEvent
getEnvID, getTypeID, isRequested, setEnvID, setRequested, setTypeID, setTypeID
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ClassLoadEvent

public ClassLoadEvent()

ClassLoadEvent

public ClassLoadEvent(java.lang.String class_name,
                      java.lang.String source_name,
                      int num_interfaces,
                      JVMPIMethod[] methods,
                      JVMPIField[] statics,
                      JVMPIField[] instances,
                      int class_id)
Method Detail

getClassName

public java.lang.String getClassName()
Get class_name.

Returns:
class_name as String.

setClassName

public void setClassName(java.lang.String class_name)
Set class_name.

Parameters:
class_name - the value to set.

getSourceName

public java.lang.String getSourceName()
Get source_name.

Returns:
source_name as String.

setSourceName

public void setSourceName(java.lang.String source_name)
Set source_name.

Parameters:
source_name - the value to set.

getNumInterfaces

public int getNumInterfaces()
Get num_interfaces.

Returns:
num_interfaces as int.

setNumInterfaces

public void setNumInterfaces(int num_interfaces)
Set num_interfaces.

Parameters:
num_interfaces - the value to set.

getNumMethods

public int getNumMethods()
Get num_methods.

Returns:
num_methods as int.

getMethods

public JVMPIMethod[] getMethods()
Get methods.

Returns:
methods as JVMPIMethod[].

getMethod

public JVMPIMethod getMethod(int index)
Get methods element at specified index.

Parameters:
index - the index.
Returns:
methods at index as JVMPIMethod.

setMethods

public void setMethods(JVMPIMethod[] methods)
Set methods.

Parameters:
methods - the value to set.

setMethod

public void setMethod(JVMPIMethod method,
                      int index)
Set methods at the specified index.

Parameters:
index - the index.

getNumStaticFields

public int getNumStaticFields()
Get num_static_fields.

Returns:
num_static_fields as int.

getStatics

public JVMPIField[] getStatics()
Get statics.

Returns:
statics as JVMPIField[].

getStatics

public JVMPIField getStatics(int index)
Get statics element at specified index.

Parameters:
index - the index.
Returns:
statics at index as JVMPIField.

setStatics

public void setStatics(JVMPIField[] statics)
Set statics.

Parameters:
statics - the value to set.

setStatics

public void setStatics(JVMPIField statik,
                       int index)
Set statics at the specified index.

Parameters:
index - the index.

getNumInstanceFields

public int getNumInstanceFields()
Get num_instance_fields.

Returns:
num_instance_fields as int.

getInstances

public JVMPIField[] getInstances()
Get instances.

Returns:
instances as JVMPIField[].

getInstances

public JVMPIField getInstances(int index)
Get instances element at specified index.

Parameters:
index - the index.
Returns:
instances at index as JVMPIField.

setInstances

public void setInstances(JVMPIField[] instances)
Set instances.

Parameters:
instances - the value to set.

setInstances

public void setInstances(JVMPIField instance,
                         int index)
Set instances at the specified index.

Parameters:
index - the index.

getClassID

public int getClassID()
Get class_id.

Specified by:
getClassID in interface ClassEvent
Returns:
class_id as int.

setClassID

public void setClassID(int class_id)
Set class_id.

Specified by:
setClassID in interface ClassEvent
Parameters:
class_id - the value to set.

getFullClassName

public java.lang.String getFullClassName()
Get fullClassName.

Returns:
fullClassName as String.

setFullClassName

public void setFullClassName(java.lang.String fullClassName)
Set fullClassName.

Parameters:
fullClassName - the value to set.

readFromStream

public void readFromStream(java.io.DataInput in,
                           short info)
                    throws java.io.IOException
Overrides:
readFromStream in class AdaptJEvent
java.io.IOException