Package org.mongojack

Annotation Type ObjectId

  • @Retention(RUNTIME)
    public @interface ObjectId
    Indicates that the property should be converted to an ObjectId before being stored in the database, and back to whatever type it is afterwards. Use this if you want an ID to have a String or byte[] value, but you want it stored in the database as an ObjectId.
    James Roper