public abstract class MisplacedClassProcessor extends java.lang.Object implements JarProcessor
| Constructor and Description |
|---|
MisplacedClassProcessor() |
| Modifier and Type | Method and Description |
|---|---|
protected java.lang.String |
formatMisplacedClassMessage(EntryStruct classStruct,
java.lang.String className) |
abstract void |
handleMisplacedClass(EntryStruct classStruct,
java.lang.String className)
Handles a class that was found at a location that does not match its fully qualified classname.
|
boolean |
process(EntryStruct struct)
Process the entry (p.ex.
|
abstract boolean |
shouldKeep()
Returns whether the entry should be included in the output.
|
abstract boolean |
shouldTransform()
Whether any JarTransformers transform and relocate the struct to its "proper" location based on
its package name, or just skip over it.
|
public abstract void handleMisplacedClass(EntryStruct classStruct, java.lang.String className)
classStruct - The jar EntryStruct for the class.className - The actual fully-qualified classname read from the binary data.public abstract boolean shouldTransform()
public abstract boolean shouldKeep()
public boolean process(EntryStruct struct) throws java.io.IOException
JarProcessor
Returns true if the processor "successfully" processed the entry. In practice,
"true" is used to indicate that the entry should be kept, and false is used to indicate the
entry should be thrown away, and doesn't indicate anything in particular about what this
JarProcessor actually did to the entry (if anything).
process in interface JarProcessorstruct - The jar entry.true if the process chain can continue after this processjava.io.IOExceptionprotected java.lang.String formatMisplacedClassMessage(EntryStruct classStruct, java.lang.String className)