Fix components name to work with Java6 and Java7.
Add if statement to properly find AppContext.
Code cleaning
Merge pull request #8 from jakubkorepta/appcontext

Fix JavaAgent to work with both java6 and java7