java.lang.Object
java.util.EventObject
org.springframework.context.ApplicationEvent
com.google.cloud.spring.data.spanner.core.mapping.event.MutationEvent
com.google.cloud.spring.data.spanner.core.mapping.event.DeleteEvent
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
AfterDeleteEvent, BeforeDeleteEvent

public class DeleteEvent extends MutationEvent
An event signaling a Cloud Spanner delete operation.
See Also:
  • Constructor Details

    • DeleteEvent

      public DeleteEvent(List<com.google.cloud.spanner.Mutation> source, Iterable targetEntities, com.google.cloud.spanner.KeySet targetKeys, Class targetType)
      Constructor.
      Parameters:
      source - the mutations for the event initially occurred. (never null)
      targetEntities - the target entities that need to be deleted.This may be null depending on the type of delete request.
      targetKeys - the target keys that need to be deleted. This may be null depending on the type of delete request.
      targetType - the target entity type that needs to be deleted. This may be null depending on the type of delete request.
  • Method Details

    • getTargetKeys

      public com.google.cloud.spanner.KeySet getTargetKeys()
      Get the list of keys that needed to be deleted.
      Returns:
      This may be null depending on the type of delete request.
    • getTargetType

      public Class getTargetType()
      Get the type of entity that needed to be deleted.
      Returns:
      This may be null depending on the type of delete request.