added Monitor class, implemented monitors untested
add monitor.java