Is it possible to move the .class files in a jar from the default package to another named package so that I can import and use them?
After browsing other questions here, I think jarjar might be exactly what im looking for, but I don't have any idea how I can use it.
So my question is how to use jarjar to repackage .class files from the default package to another named package?
EDIT: I want to clarify something - I do not have the sources of the jar I want to repackage, so I don't know how I could recompile the code. Obfuscation and reflection is out of the question.
EDIT2: It appears its extremely simple to do using jarjar :) java -jar jarjar.jar process rules.rules in.jar out.jar
rules.rules look something like this: rule a net.ylivay.src.a
Problem solved!