Interface ExposesProperties<T extends ExposesProperties<?> & PropertyContainer>

  • Type Parameters:
    T - type of the object holding the specified properties
    All Known Subinterfaces:
    Node, Relationship
    All Known Implementing Classes:
    NodeBase, RelationshipBase

    public interface ExposesProperties<T extends ExposesProperties<?> & PropertyContainer>
    A container that exposes methods to add properties with values to nodes or relationships.
    Since:
    1.1
    Author:
    Michael J. Simons
    • Method Detail

      • withProperties

        @NotNull
        @Contract(pure=true)
        T withProperties​(MapExpression newProperties)
        Creates a a copy of this property container with additional properties. Creates a property container without properties when no properties are passed to this method.
        Parameters:
        newProperties - the new properties (can be null to remove exiting properties).
        Returns:
        The new property container.
      • withProperties

        @NotNull
        @Contract(pure=true)
        T withProperties​(Object... keysAndValues)
        Creates a a copy of this property container with additional properties. Creates a property container without properties when no properties are passed to this method.
        Parameters:
        keysAndValues - A list of key and values. Must be an even number, with alternating String and Expression.
        Returns:
        The new property container.
      • withProperties

        @NotNull
        @Contract(pure=true)
        T withProperties​(Map<String,​Object> newProperties)
        Creates a a copy of this property container with additional properties.
        Parameters:
        newProperties - A map with the new properties
        Returns:
        The new property container.