On Mon, Jun 15, 2015 at 6:17 PM, Dave Cramer <pg@fastcrypt.com> wrote:
How can you use the same name and different bytecode versions ?
Short answer is you can't.
Longer answer is, as long as the classes don't use types that aren't defined in the newer interface, you can include implementations for methods that aren't defined in an older interface definition. It's only a problem if those methods use types that don't exist (ex: if a function signature used the new Java 8 time types). You'd also need to either compile with the older target bytecode version or actually build multiple versions off the same source.
I think a purely Maven based build with separate targets should be possible via a generated-sources plugin. Off the top of my head I'm not sure which plugins it would use though. It's been a while since I wrote anything like that though I do remember it being a bit of a pain to get right. On the plus side we only have to figure it out once right? :)
I'm a big fan of Mavenizing the build process. A lot of the value of it will come from how it will simplify things like adding tests. It eliminates a lot of the double and sometimes triple entry (i.e. add the test class, add it to a suite, add the suite to build.xml).