Add initial serialization support for tuple members.

Deserialization support is missing, as well as handling attributes of tuple members.
Inline tuple fields for @asArray seriailzed structs and add basic serialization unit tests.
Fix MongoCollection.aggregate and add array parameter special case. Fixes #783.
Add unit tests for tuple seriailzation and work around strange isInstanceOf bug.