wt.tools.profiler
Class ProfilerServerHelper

java.lang.Object
  extended bywt.tools.profiler.ProfilerServerHelper
All Implemented Interfaces:
Serializable

public class ProfilerServerHelper
extends Object
implements Serializable

Methods to be called from server side

Supported API: true

Extendable: false

See Also:
Serialized Form

Field Summary
private static String CLASSNAME
           
private static String RESOURCE
           
static ProfilerServiceSvr service
          

Supported API: true
 
Constructor Summary
ProfilerServerHelper()
           
 
Method Summary
static void regProfilingOperation(ProfilingKey key, ProfilingListener adapter)
          Any service/function that wants to make one of its operations profilable, creates an adapter & a listener.
static void repProfilingData(ProfilingKey key, Object occuranceKey, int cost, Object occuranceData)
          Operations being profiled will report data using this method.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RESOURCE

private static final String RESOURCE
See Also:
Constant Field Values

CLASSNAME

private static final String CLASSNAME

service

public static final ProfilerServiceSvr service


Supported API: true

Constructor Detail

ProfilerServerHelper

public ProfilerServerHelper()
Method Detail

regProfilingOperation

public static void regProfilingOperation(ProfilingKey key,
                                         ProfilingListener adapter)
Any service/function that wants to make one of its operations profilable, creates an adapter & a listener. It then calls this function passing it the adapter and listener, to let the StandardProfilingService know that it is available for profiling.

Parameters:
key - The operation(adapter) that is being profiled
adapter - The listener associated with the operation(adapter) being profiled. This listener can be enabled or disbled thro the profiler GUI, which enables/disables a static flag that is tested by the operation, before reporting its data to the profiling service

repProfilingData

public static void repProfilingData(ProfilingKey key,
                                    Object occuranceKey,
                                    int cost,
                                    Object occuranceData)
Operations being profiled will report data using this method.

Parameters:
key - The operation being profiled
occuranceKey - The occurance key like a SQL query string, dn etc
cost - The cost of the occurance eg num rows returned for SQL, exe time for an SQL
occuranceData - Additional Data associated with the occurance eg in case of SQL it will be bind parameters