if (mimeType == null) mimeType = DEFAULT_MIME_TYPE;
addProperty(properties, factory, JcrLexicon.MIMETYPE, mimeType);
if (os.toByteArray().length > 0) {
// Now put the file's content into the "jcr:data" property ...
BinaryFactory binaryFactory = getExecutionContext().getValueFactories().getBinaryFactory();
addProperty(properties, factory, JcrLexicon.DATA, binaryFactory.create(os.toByteArray()));
}
}
} else {
// Determine the corresponding file path for this object ...
String filePath = getPathAsString(requestedPath);