A few more BSON fixes
This commit is contained in:
parent
112870b537
commit
b8d6f57602
Binary file not shown.
Binary file not shown.
|
@ -265,7 +265,10 @@ public class RubyBSONCallback implements BSONCallback {
|
|||
|
||||
public void gotObjectId( String name , ObjectId id ){
|
||||
byte[] jbytes = id.toByteArray();
|
||||
RubyArray arg = ja2ra(jbytes);
|
||||
RubyArray arg = RubyArray.newArray( _runtime, 12 );
|
||||
for( int i=0; i<jbytes.length; i++) {
|
||||
arg.store( i, _runtime.newFixnum(jbytes[i] & 0xFF) );
|
||||
}
|
||||
Object[] args = new Object[] { arg };
|
||||
|
||||
Object result = JavaEmbedUtils.invokeMethod(_runtime, _rbclsObjectId, "new", args, Object.class);
|
||||
|
|
|
@ -565,8 +565,6 @@ module BSON
|
|||
ARRAY
|
||||
when Regexp
|
||||
REGEX
|
||||
when ObjectID
|
||||
OID
|
||||
when ObjectId
|
||||
OID
|
||||
when DBRef
|
||||
|
|
Loading…
Reference in New Issue