@Override public Edge join(Edge edge, Vertex vertex) throws Exception { PropertyValue newEdgeValue = vertex.getPropertyValue(propertyKey); if (edge.hasProperty(propertyKey)) { if (edge.getPropertyValue(propertyKey).compareTo(newEdgeValue) < 0) { return edge; } } edge.setProperty(propertyKey, newEdgeValue); return edge; } }
@Override public Edge join(Edge edge, Vertex vertex) throws Exception { PropertyValue newEdgeValue = vertex.getPropertyValue(propertyKey); if (edge.hasProperty(propertyKey)) { if (edge.getPropertyValue(propertyKey).compareTo(newEdgeValue) < 0) { return edge; } } edge.setProperty(propertyKey, newEdgeValue); return edge; } }
.stream() .filter(e -> e.hasProperty(PROP_STATUS)) .filter(e -> e.getPropertyValue(PROP_STATUS).getString().matches(PATTERN_EDGE_PROP.pattern())) .collect(Collectors.toList());
.stream() .filter(e -> e.hasProperty(PROP_STATUS)) .filter(e -> e.getPropertyValue(PROP_STATUS).getString().matches(PATTERN_EDGE_PROP.pattern())) .collect(Collectors.toList());
.filter(e -> e.hasProperty(PROP_SINCE)) .filter(e -> e.getPropertyValue(PROP_SINCE).equals(propertyValueSince)) .collect(Collectors.toList());
.stream() .filter(e -> e.hasProperty(PROP_SINCE)) .filter(e -> e.getPropertyValue(PROP_SINCE).compareTo(propertyValueSince) > 0) .collect(Collectors.toList());
.stream() .filter(e -> e.getLabel().matches(PATTERN_EDGE.pattern()) || (e.hasProperty(PROP_SINCE) && e.getPropertyValue(PROP_SINCE).getInt() < 2015)) .collect(Collectors.toList());
.filter(e -> e.hasProperty(PROP_SINCE)) .filter(e -> e.getPropertyValue(PROP_SINCE).equals(propertyValueSince)) .collect(Collectors.toList());
.stream() .filter(e -> e.hasProperty(PROP_SINCE)) .filter(e -> e.getPropertyValue(PROP_SINCE).compareTo(propertyValueSince) > 0) .collect(Collectors.toList());
.stream() .filter(e -> e.getLabel().matches(PATTERN_EDGE.pattern()) || (e.hasProperty(PROP_SINCE) && e.getPropertyValue(PROP_SINCE).getInt() < 2015)) .collect(Collectors.toList());