moved functions to prototype
added number and numberObject as types
revised state entry types, added knownTypes object
minor bugfixes
shortened knownTypes definitions
bugfix: toggle works again
added getStringValue and setStringValue
setStringValue does not change the value if parsing failed