Class CosmosMappingEvent<T>

  • All Implemented Interfaces:
    Serializable
    Direct Known Subclasses:
    AfterLoadEvent

    public class CosmosMappingEvent<T>
    extends org.springframework.context.ApplicationEvent
    Base Class that all cosmos related spring application events extend Ported to cosmos from spring-data-mongo https://github.com/spring-projects/spring-data-mongodb/blob/main/spring-data-mongodb/src/main/java/org/springframework/data/mongodb/core/mapping/event/MongoMappingEvent.java
    See Also:
    Serialized Form
    • Constructor Detail

      • CosmosMappingEvent

        public CosmosMappingEvent​(T source,
                                  @Nullable
                                  JsonNode document,
                                  @Nullable
                                  String containerName)
        Creates new CosmosMappingEvent.
        Parameters:
        source - must not be null.
        document - can be null.
        containerName - can be null.
    • Method Detail

      • getDocument

        @Nullable
        public JsonNode getDocument()
        Returns:
        null if not set.
      • getContainerName

        @Nullable
        public String getContainerName()
        Get the container the event refers to.
        Returns:
        null if not set.