Package org.jboss.byteman.contrib.dtest
Class BytemanTestHelper
java.lang.Object
org.jboss.byteman.rule.helper.Helper
org.jboss.byteman.contrib.dtest.BytemanTestHelper
Helper class containing functions used by Byteman rules created by the dtest framework.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate Object[]
convertForRemoting
(Object[] input) Convert Objects to their String representation for transmission over RMI.boolean
Print a message during rule execution.void
remoteTrace
(String className, String methodName, Object[] dollarStar) Send trace information to a remote listener.Methods inherited from class org.jboss.byteman.rule.helper.Helper
activated, addCountDown, callerCheck, callerEquals, callerEquals, callerEquals, callerEquals, callerEquals, callerEquals, callerEquals, callerEquals, callerEquals, callerMatches, callerMatches, callerMatches, callerMatches, callerMatches, callerMatches, callerMatches, callerMatches, callerMatches, clear, clearLinks, clearLinks, closeTrace, countDown, createCountDown, createCounter, createCounter, createJoin, createLinkMap, createRendezvous, createRendezvous, createTimer, deactivated, debug, decrementCounter, delay, deleteCounter, deleteLinkMap, deleteRendezvous, deleteTimer, err, errTraceException, flag, flagged, formatAllStacks, formatAllStacks, formatAllStacks, formatAllStacks, formatStack, formatStack, formatStack, formatStack, formatStackBetween, formatStackBetween, formatStackBetween, formatStackBetween, formatStackBetween, formatStackBetween, formatStackBetweenMatches, formatStackBetweenMatches, formatStackBetweenMatches, formatStackBetweenMatches, formatStackBetweenMatches, formatStackBetweenMatches, formatStackMatching, formatStackMatching, formatStackMatching, formatStackMatching, formatStackMatching, formatStackMatching, formatStackRange, formatThreadStack, formatThreadStack, formatThreadStack, formatThreadStack, getCountDown, getElapsedTimeFromTimer, getObjectSize, getRendezvous, getStack, incrementCounter, incrementCounter, installed, isCountDown, isJoin, isRendezvous, joinEnlist, joinWait, joinWait, killJVM, killJVM, killThread, link, link, linked, linked, linkNames, linkNames, linkValues, linkValues, matchIndex, noisy, noisyTraceException, openTrace, openTrace, out, outTraceException, printFrame, printlnFrame, readCounter, readCounter, rendezvous, rendezvous, resetTimer, setTriggering, signalKill, signalKill, signalThrow, signalThrow, signalWake, signalWake, toString, trace, trace, traceAllStacks, traceAllStacks, traceAllStacks, traceAllStacks, traceAllStacks, traceAllStacks, traceClose, traceln, traceln, traceOpen, traceOpen, traceStack, traceStack, traceStack, traceStack, traceStack, traceStack, traceStackBetween, traceStackBetween, traceStackBetween, traceStackBetween, traceStackBetween, traceStackBetween, traceStackBetween, traceStackBetween, traceStackBetween, traceStackBetweenMatches, traceStackBetweenMatches, traceStackBetweenMatches, traceStackBetweenMatches, traceStackBetweenMatches, traceStackBetweenMatches, traceStackBetweenMatches, traceStackBetweenMatches, traceStackBetweenMatches, traceStackMatching, traceStackMatching, traceStackMatching, traceStackMatching, traceStackMatching, traceStackMatching, traceStackMatching, traceStackMatching, traceStackMatching, traceStackRange, traceThreadStack, traceThreadStack, traceThreadStack, traceThreadStack, traceThreadStack, traceThreadStack, triggerIndex, uninstalled, unlink, unlink, verbose, verboseTraceException, waitFor, waitFor, waiting
-
Field Details
-
RMIREGISTRY_PORT_PROPERTY_NAME
- See Also:
-
DEFAULT_RMI_PORT
static final int DEFAULT_RMI_PORT- See Also:
-
targetInstances
-
registry
-
-
Constructor Details
-
BytemanTestHelper
- Throws:
Exception
-
-
Method Details
-
debug
Print a message during rule execution. n.b. this always returns true which means it can be invoked during condition execution- Parameters:
text
- the message to be printed as trace outputobject0
- an object, typically the rule target, whose String representation will be added to the output.- Returns:
- true
-
remoteTrace
Send trace information to a remote listener. A Rule will normally be installed to invoke this on entry to each method of interest.- Parameters:
className
- the name of the instrumented, i.e. traced, classmethodName
- the name of the traced method.dollarStar
- the method args starting with this- Throws:
Exception
- if the info cannot be sent- See Also:
-
convertForRemoting
Convert Objects to their String representation for transmission over RMI.- Parameters:
input
- An Array of Objects, possibly including nulls.- Returns:
- An Array of length equivalent to the input, containing corresponding nulls or the String representation of the input.
-