if (dataObj == null)
throw new RuntimeException("Data object passed was NULL.");
if (dataObj.getId() == null)
throw new RuntimeException("Data object's ID was NULL.");
DataProducedDocument activity = DataProducedDocument.Factory.newInstance();
DataProductNotificationType activityType = activity.addNewDataProduced();
// set the data product to the produced data
DataProductType dataProduct = activityType.addNewDataProduct();
// set data ID and size
dataProduct.setId(dataObj.getId().toString());