log.warn("METS Disseminator is skipping "+type+" without handle: " + dso.toString());
}
else
{
//create <mptr> with handle reference
Mptr mptr = new Mptr();
mptr.setID(gensym("mptr"));
mptr.setLOCTYPE(Loctype.HANDLE);
mptr.setXlinkHref(handle);
div.getContent().add(mptr);
}
//determine file extension of child references,
//based on whether we are exporting just a manifest or a full Zip pkg
String childFileExtension = (params.getBooleanProperty("manifestOnly", false)) ? "xml" : "zip";
// Always create <mptr> with file-name reference to child package
// This is what DSpace will expect the child package to be named during ingestion
// (NOTE: without this reference, DSpace will be unable to restore any child objects during ingestion)
Mptr mptr2 = new Mptr();
mptr2.setID(gensym("mptr"));
mptr2.setLOCTYPE(Loctype.URL);
//we get the name of the child package from the Packager -- as it is what will actually create this child pkg file
mptr2.setXlinkHref(PackageUtils.getPackageName(dso, childFileExtension));
div.getContent().add(mptr2);
return div;
}