Made two accidentally-public message classes package private
Added general ability to encode DBRef and for DocumentCodec to decode DBRef.

  JAVA-1508