Observer pattern Java implementation added