Class ReflectionEncryptionEventListener

java.lang.Object
org.springframework.data.mongodb.core.mapping.event.AbstractMongoEventListener
All Implemented Interfaces:
EventListener, org.springframework.context.ApplicationListener

public class ReflectionEncryptionEventListener extends AbstractEncryptionEventListener<ReflectionEncryptionEventListener>
This is a reimplementation of CachedEncryptionEventListener, to support polymorphism. This means that while instead of walking by pre-cached class reflection, we have to walk by the Document provided and try to match reflection data to it.
  • Constructor Details

    • ReflectionEncryptionEventListener

      public ReflectionEncryptionEventListener(com.bol.crypt.CryptVault cryptVault)
    • ReflectionEncryptionEventListener

      public ReflectionEncryptionEventListener(com.bol.crypt.CryptVault cryptVault, FieldEncryptedPredicate fieldEncryptedPredicate)
  • Method Details

    • onAfterLoad

      public void onAfterLoad(org.springframework.data.mongodb.core.mapping.event.AfterLoadEvent event)
      Overrides:
      onAfterLoad in class org.springframework.data.mongodb.core.mapping.event.AbstractMongoEventListener
    • onBeforeSave

      public void onBeforeSave(org.springframework.data.mongodb.core.mapping.event.BeforeSaveEvent event)
      Overrides:
      onBeforeSave in class org.springframework.data.mongodb.core.mapping.event.AbstractMongoEventListener