Updated classes to match observer pattern.