Interface ChangeValidatorAdapter<E extends EntityType<E>>

    • Method Detail

      • getSupportedChangeOperation

        SupportedChangeOperation getSupportedChangeOperation()
        Returns:
        the supported change operation
      • fieldsToFetch

        java.util.stream.Stream<? extends EntityField<?,​?>> fieldsToFetch()
        Returns:
        a list of fields to fetch
      • validate

        ValidationError validate​(EntityChange<E> entityChange,
                                 CurrentEntityState currentState)
        Called by the framework to validate the fields in entity change. The implementation can query the entity only for the fields it has declared in fieldsToFetch().
        Parameters:
        entityChange - entity change
        currentState - existing entity
        Returns:
        a validation error if any, null if none