Add support for Java enums, include tests

see:https://jira.mongodb.org/browse/JAVA-268