Skip to content

Navigation Menu

Sign up
atheken edited this page Aug 13, 2010 · 28 revisions

MongoSharp’s BSON serializer is very powerful, but you must be careful not to abuse it.

h2.Requirements for Serialization of a Type:

  • All readable properties may be:
    • int
    • bool
    • double (floats will be stored as doubles in the db)
    • datetime
    • string
    • byte[]
    • BSONOID (this is the default "_id" value that’s generated if you don’t specify something different)
    • Regex
    • Guid
    • IEnumerable
    • T ("where T:class, new()" and follows this rule. )
    • A few other types should be supported soon.
  • Cyclic graphs are not checked and attempting to serialize them will crash your app, maybe someday this will change, but not this day.

Clone this wiki locally

AltStyle によって変換されたページ (->オリジナル) /