Extension hooks and skeleton of phongo, and basic bson implementation

`$id` can be anything, but will likely be an ObjectId. `$index` is an integer. Looks like `$index` is missing from the `@param` block below.