Fixed Java Code too large error