About Loggifier

Documentation

See the Loggifier home page.

Description

This plugin-in defines a new ANT task 'de.unkrig.loggify' which can be used from build scripts executed in the same JRE as the workspace.

Attributes of the 'de.unkrig.loggify' task
selector
If defined, then only those .class files which match the 'combined wildcard pattern' are loggified.
outdir
If not defined, then the input files and dirs are processed 'in-place'. Otherwise, the input files and dirs are copied to the given output directory while being loggified.
keeporiginals
If 'outdir' is not set ('in-place loggification') and 'keeporiginals=true', then copies of the original (unloggified) input files are kept with names similar to the original file names.
debug
Subelements of the 'de.unkrig.loggify' task
rule
Inject logging code according to the given rule.
The rule format is:
  action[,action]...=level[:expression]
action is one of [ CLINIT ENTRY RETURN THROW LOAD STORE INVOKE RESULT ]
level is one of [ OFF SEVERE WARNING INFO CONFIG FINE FINER FINEST ]
expression is like '(eq || eq) && !eq', where
eq is 'var == cwp', where
var is one of [ class source line ] (for action 'STORE' also 'name')
cwd is a 'combined wildcard pattern' in single quotes
fileset
Set of files to loggify. '.class' files are loggified, ZIP format files are scanned recursively for '.class' files, and all other files are left unmodified (in-place loggification) or copied unmodified to 'outdir'.
dirset
Set of directories to loggify. All '.class' files in each directory tree (and also in ZIP files and nested ZIP files) are loggified (if they match the 'selector').
Discriminator subelements
or
Returns true iff any of the discriminator subelements returns true.
and
Returns true iff all of the discriminator subelements returns true.
class
Returns true iff the declaring class matches the 'name' (combined wildcard pattern) or the 'regex'.
method
Returns true iff the declaring method matches the 'name' (combined wildcard pattern) or the 'regex'.
line
Returns true iff the line number matches the 'number' (integer pattern).
Combined wildcard patterns
Examples:
Pattern characterMatches
*Any sequence of characters except '/' and '!'
**Any sequence of characters except '!'
***Any sequence of characters
?Any character except '/' and '!'
[abc]'a', 'b' and 'c'
[^abc]Any character except 'a', 'b' and 'c'
[A-Z]All characters from 'A' to 'Z'
any-other-characterThat character
\any-characterThat character
Integer patterns
Examples:
Pattern characterMatches
77
7;97 and 9
7-97 through 9
7-7 and up
-99 and less
x;yx and y (where x and y are integer patterns)

Change Log

Version 1.0.0
Changes since the previous version: