Macker
What's New in Macker 0.4.x
New features
Version 0.4.2:
- Added an Ant task for report formatting, with built-in support for HTML/CSS output, and extensibility through XSLT. (more)
Version 0.4:
- Filters, a new construct, open the door to customizable pattern behavior. The first set of filters match based on supertypes and basic class attributes. The next version of Macker will include more sophisticated filters. (more)
- Rules now have severity levels -- you can generate warnings without failing the Ant build, or include debug messages which are hidden during a normal run. (more)
- Macker can now generate XML reports. (more)
- Message rules can print arbitrary messages, optionally with error or warning status. (more)
- The special from/to variables are now available to patterns in an access rule, in addition to the message. Two new variables give just the from/to package name. (more) Two new patterns match the from/to classes. (more)
- The Ant task can now set a property when rule checking fails, and supports limiting the number of errors / messages printed to the console. (more)
Changes to existing features
- The
regex
attribute is now deprecated in favor of class
, which will make future features more readable. (Only the name has changed; both do the same thing.)
- For each now also matches against classes one reference out from the primary classes, instead of just the primary classes themselves. This lets you check against modules which are not part of the primary classes, but, for example, in a jar from a different project.
- Verbose output shows classes in sorted order.
Implementation changes
- Macker now uses Jakarta BCEL for class file parsing. This speeds things up a hair, and eliminates the warning messages JClasslib used to generate.
- Class analysis now is vastly more detailed: it includes superclass, interfaces, and access modifiers, and internally distinguishes different types of signature-level references. This richer analysis will manifest itself in richer patterns and rules in future versions of Macker. (Right now, it probably just cancels out the speed benefits of BCEL.)
- The internal event callback mechanism is better structured (inching closer to IDE integration).
- Macker now forces validation against its internal DTD.
- There's a small but steadily growing regression test suite.
Bug fixes
Version 0.4.1:
- Foreach no longer always causes rule checking to fail (794536). This bug, introduced in 0.4, was serious enough to warrant an immediate patch.
Version 0.4:
- Running under Java 1.4 no longer generates "major version" warning messages.
- The Ant task now always honors the
failonerror
attribute (794422).
- Fixed two bugs (729149, 793964) which caused certain compositions of named patterns to incorrectly modify the patterns' definitions.
- Fixed a bug in which a certain lazy loading sequence would incorrectly cause access rules to match the reference from a class to itself.
- Macker now detects array instantiations correctly (791385), except the instantiation of single-dimensioned arrays of primitives, which generate special bytecode (791721).
Known Issues
See the bug tracker on Sourceforge.