if (descriptor instanceof HFile) {
Path descriptorPath = ((HFile) descriptor).getPath();
fileName = descriptorPath.getName();
Path parent = descriptorPath.getParent();
parentName = parent.toString();
parentContainer = new HDirectory((HDataStorage)storage,parent);
}
ElementDescriptor metaFilePath = storage.asElement(parentName, prefix+"."+fileName);
// if the file has a custom schema, use it
if (metaFilePath.exists()) {