Added support so subclasses and implementations of interfaces will just wokr with deserialization if possible.