XmldbURI binUri = XmldbURI.create(diffUri.toString() + BINARY_SUFFIX);
broker.copyResource(transaction, document, vCollection, binUri);
//Create metadata about the last Binary Version
sax.startElement(ELEMENT_REPLACED_BINARY, null);
sax.attribute(ATTRIBUTE_REF, binUri.toString());
sax.endElement(ELEMENT_REPLACED_BINARY);
} else if(lastRev instanceof BinaryDocument) {
//create a copy of the last XML revision
XmldbURI xmlUri = XmldbURI.create(diffUri.toString() + XML_SUFFIX);
broker.copyResource(transaction, document, vCollection, xmlUri);