Added class declarations and definitions