@Override public final Property getLastProperty() { return propertyMap.getLastProperty(); }
/** @since 0.17 or earlier */ @Override public final Property getLastProperty() { return propertyMap.getLastProperty(); }
/** @since 0.17 or earlier */ @Override public final Property getLastProperty() { return propertyMap.getLastProperty(); }
public PropertyMap getOwningMap(Property value) { PropertyMap current = this; while (!current.isEmpty()) { if (current.getLastProperty().equals(value)) { return current; } current = current.getParentMap(); } return null; }
public PropertyMap removeCopy(Property value) { Deque<Property> shelve = new ArrayDeque<>(); PropertyMap current = this; while (!current.isEmpty()) { if (current.getLastProperty().equals(value)) { PropertyMap newMap = current.getParentMap(); for (Property property : shelve) { newMap = newMap.putCopy(property); } return newMap; } else { shelve.push(current.getLastProperty()); current = current.getParentMap(); } } return this; }
private static int makePropertyCount(ShapeImpl parent, PropertyMap propertyMap) { return parent.propertyCount + ((propertyMap.size() > parent.propertyMap.size() && !propertyMap.getLastProperty().isHidden() && !propertyMap.getLastProperty().isShadow()) ? 1 : 0); }
public PropertyMap replaceCopy(Property oldValue, Property newValue) { Deque<Property> shelve = new ArrayDeque<>(); PropertyMap current = this; while (!current.isEmpty()) { if (current.getLastProperty().equals(oldValue)) { PropertyMap newMap = current.getParentMap(); newMap = newMap.putCopy(newValue); for (Property property : shelve) { newMap = newMap.putCopy(property); } return newMap; } else { shelve.push(current.getLastProperty()); current = current.getParentMap(); } } return this; }
private static int makePropertyCount(ShapeImpl parent, PropertyMap propertyMap) { if (propertyMap.size() > parent.propertyMap.size()) { Property lastProperty = propertyMap.getLastProperty(); if (!lastProperty.isHidden()) { return parent.propertyCount + 1; } } return parent.propertyCount; }
private static int makePropertyCount(ShapeImpl parent, PropertyMap propertyMap) { if (propertyMap.size() > parent.propertyMap.size()) { Property lastProperty = propertyMap.getLastProperty(); if (!lastProperty.isHidden()) { return parent.propertyCount + 1; } } return parent.propertyCount; }
private static Property[] makePropertiesList(ShapeImpl parent, PropertyMap propertyMap) { Property[] properties = parent.propertyArray; if (properties != null && propertyMap.size() != parent.propertyMap.size()) { Property lastProperty = propertyMap.getLastProperty(); if (lastProperty != null && !lastProperty.isHidden()) { propertyListAllocCount.inc(); if (!lastProperty.isShadow()) { properties = Arrays.copyOf(properties, properties.length + 1); properties[properties.length - 1] = lastProperty; } else { properties = Arrays.copyOf(properties, properties.length); for (int i = 0; i < properties.length; i++) { if (properties[i].isSame(lastProperty)) { properties[i] = lastProperty; } } } } else { propertyListShareCount.inc(); } } return properties; }