code: public DBCursor setDecoderFactory(final DBDecoderFactory factory) {
          this.decoderFactory = factory;
  
          //Not creating new CompoundDBObjectCodec because we don't care about encoder.
          this.decoder = new DBDecoderAdapter(factory.create(), collection, getCollection().getBufferPool());
          return this;
      }
docs: Sets the factory that will be used create a {@code DBDecoder} that will be used to decode BSON documents into DBObject instances.
  
  @param factory the DBDecoderFactory
  @return {@code this} so calls can be chained