new class to store and retrieve the current lamp state