Login | Register
My pages Projects Community openCollabNet

AOP metrics by command line

Description

Since the 0.3 version aopmetrics can be run using command line.

All commandline options are similar to ant task ones. Therefore for details please refer to aopmetrics ant task description.

Here is a summary of aopmetrics options:

aopmetrics.sh -help
usage: aopmetrics [options]

where:
 -charset <charset>       Specifies character encoding of given sources.
 -classpath <classpath>   Specifies user class path.
 -configfile <file>       Specifies a config file (.lst), which is commonly used
                          in AspectJ projects. The config file contains paths of all source files
                          (separated by newline).
 -export <type>           Specifies an export type. Currently only 'xml' and
                          'xls' types are supported.
 -help                    Prints this message.
 -resultsfile <file>      Specifies a file, where aopmetrics writes results of
                          all measurements. If the file is not specified, then results will be printed to
                          standard output.
 -sourcelevel <level>     Specifies source compiliance level. The value is
                          passed to the AspectJ compiler. Currently, the compiler supports '1.3', '1.4'
                          and '1.5' levels. Default: '1.4'
 -verbose <level>         Specifies verbosity level. The attribute is useful for
                          debugging. Currently, 'normal', 'info' and 'debug' levels are supported.
                          Default: 'normal'
 -workdir <directory>     Specifies a directory, where aopmetrics stores
                          temporary files (compiled sources by AspectJ compiler). If the directory doesn't
                          exist, it will be created it.

Examples

Here are some examples for Linux.

 aopmetrics.sh  -configfile config.lst  -workdir build/work  -resultfile results.xml

More complex example:

 aopmetrics.sh -configfile config.lst -workdir build/work -sourcelevel 1.4 
   -export xls  -resultsfile results.xls 
   -classpath lib/xstream-1.1.1.jar:lib/xpp3_min-1.1.3.4.I.jar