made seperate java6 and java 8 implementations of some classes