Package org.neo4j.cdc.client.selector
Class RelationshipSelector
- java.lang.Object
-
- org.neo4j.cdc.client.selector.EntitySelector
-
- org.neo4j.cdc.client.selector.RelationshipSelector
-
- All Implemented Interfaces:
Selector
public class RelationshipSelector extends EntitySelector
Provides a means to filter changes for nodes.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classRelationshipSelector.RelationshipSelectorBuilder-
Nested classes/interfaces inherited from class org.neo4j.cdc.client.selector.EntitySelector
EntitySelector.Builder<T extends EntitySelector.Builder<?,?>,S extends EntitySelector>
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Map<String,Object>asMap()Returns a map representation of this selector to be sent over to server.static RelationshipSelector.RelationshipSelectorBuilderbuilder()Returns a builder instance forRelationshipSelector.booleanequals(Object o)@NotNull RelationshipNodeSelectorgetEnd()Selector for the end node of the changed relationship.@NotNull Map<String,Object>getKey()Map of property names and values that identifies the relationship.@NotNull RelationshipNodeSelectorgetStart()Selector for the start node of the changed relationship.@Nullable StringgetType()Relationship type of the changed relationship.inthashCode()booleanmatches(ChangeEvent e)Checks if a given change event matches this selector.-
Methods inherited from class org.neo4j.cdc.client.selector.EntitySelector
applyProperties, getAuthenticatedUser, getChangesTo, getExcludeProperties, getExecutingUser, getIncludeProperties, getOperation, getTxMetadata
-
-
-
-
Method Detail
-
getType
@Nullable public @Nullable String getType()
Relationship type of the changed relationship.- Returns:
- relationship type
-
getStart
@NotNull public @NotNull RelationshipNodeSelector getStart()
Selector for the start node of the changed relationship.- Returns:
- relationship node selector
-
getEnd
@NotNull public @NotNull RelationshipNodeSelector getEnd()
Selector for the end node of the changed relationship.- Returns:
- relationship node selector
-
getKey
@NotNull public @NotNull Map<String,Object> getKey()
Map of property names and values that identifies the relationship. All the property names needs to be part of a Key constraint and values need to match.- Returns:
- map of property name and values
-
matches
public boolean matches(ChangeEvent e)
Description copied from class:EntitySelectorChecks if a given change event matches this selector.- Specified by:
matchesin interfaceSelector- Overrides:
matchesin classEntitySelector- Parameters:
e- change event to check- Returns:
- whether the event matches or not
-
asMap
public Map<String,Object> asMap()
Description copied from class:EntitySelectorReturns a map representation of this selector to be sent over to server.- Specified by:
asMapin interfaceSelector- Overrides:
asMapin classEntitySelector- Returns:
- map representation
-
equals
public boolean equals(Object o)
- Overrides:
equalsin classEntitySelector
-
hashCode
public int hashCode()
- Overrides:
hashCodein classEntitySelector
-
builder
public static RelationshipSelector.RelationshipSelectorBuilder builder()
Returns a builder instance forRelationshipSelector.- Returns:
- builder instance
-
-