-
Type: Task
-
Resolution: Done
-
Priority: Major - P3
-
Affects Version/s: 0.6.3
-
Component/s: None
-
None
Per the serialization spec, an MongoDB\Driver\Exception\UnexpectedValueException should be thrown when:
- bsonSerialize() does not return an array or stdClass instance
An MongoDB\Driver\Exception\InvalidArgumentException should be thrown when:
- The custom class specified in the type map does not exist, does not implement Unserializable, or is not instantiatable (i.e. it's abstract).
We don't throw exceptions if the deserialization class inferred by __pclass is unusable (i.e. missing, not Unserializable, or not instantiatable).