if (!diff.getNewFeatureType().equals(ObjectId.NULL) && !diff.getOldFeatureType().equals(ObjectId.NULL)) { RevFeatureType oldFeatureType = getFeatureTypeFromId(diff.getOldFeatureType()).get(); RevFeatureType newFeatureType = getFeatureTypeFromId(diff.getNewFeatureType()).get(); ImmutableList<PropertyDescriptor> oldDescriptors = oldFeatureType.descriptors(); ImmutableList<PropertyDescriptor> newDescriptors = newFeatureType.descriptors();
if (!diff.getNewFeatureType().equals(ObjectId.NULL) && !diff.getOldFeatureType().equals(ObjectId.NULL)) { RevFeatureType oldFeatureType = getFeatureTypeFromId(diff.getOldFeatureType()).get(); RevFeatureType newFeatureType = getFeatureTypeFromId(diff.getNewFeatureType()).get(); ImmutableList<PropertyDescriptor> oldDescriptors = oldFeatureType.descriptors(); ImmutableList<PropertyDescriptor> newDescriptors = newFeatureType.descriptors();
Optional<RevFeatureType> featureType; if (diff.getOldFeatureType().isNull()) { featureType = patch.getFeatureTypeFromId(diff.getNewFeatureType()); workTree.createTypeTree(diff.getPath(), featureType.get().type()); } else if (diff.getNewFeatureType().isNull()) { workTree.delete(diff.getPath()); } else { featureType = patch.getFeatureTypeFromId(diff.getNewFeatureType()); workTree.updateTypeTree(diff.getPath(), featureType.get().type());
Optional<RevFeatureType> featureType; if (diff.getOldFeatureType().isNull()) { featureType = patch.getFeatureTypeFromId(diff.getNewFeatureType()); workTree.createTypeTree(diff.getPath(), featureType.get().type()); } else if (diff.getNewFeatureType().isNull()) { workTree.delete(diff.getPath()); } else { featureType = patch.getFeatureTypeFromId(diff.getNewFeatureType()); workTree.updateTypeTree(diff.getPath(), featureType.get().type());