Class AuthDataUpdatePersistenceHandler
java.lang.Object
com.broadleafcommerce.auth.user.listener.AuthDataUpdatePersistenceHandler
- All Implemented Interfaces:
com.broadleafcommerce.common.messaging.PersistenceHandler
- Direct Known Subclasses:
CustomerPersistenceHandler,OperationAwarePersistenceHandler
public abstract class AuthDataUpdatePersistenceHandler
extends Object
implements com.broadleafcommerce.common.messaging.PersistenceHandler
Handles messages from the Persistence channel for other services that can impact the data in the
authentication service, such as roles, permissions, and users. This is designed to perform a
replacement of existing data within this service with data from an external service.
- Author:
- Phillip Verheyden (phillipuniverse)
-
Constructor Summary
ConstructorsConstructorDescriptionAuthDataUpdatePersistenceHandler(com.fasterxml.jackson.databind.ObjectMapper objectMapper) -
Method Summary
Modifier and TypeMethodDescriptioncom.fasterxml.jackson.databind.ObjectMappervoidbooleanisNodeNull(com.fasterxml.jackson.databind.JsonNode jsonNode) Checks if a JSON Node is equal to null or if the Node itself is present but represents the JSON literal value of "null".booleanisValidType(String reportedType, String projectionType) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.broadleafcommerce.common.messaging.PersistenceHandler
getSupportedSimpleTypeNames, hook, processStateChange, validate
-
Constructor Details
-
AuthDataUpdatePersistenceHandler
public AuthDataUpdatePersistenceHandler(com.fasterxml.jackson.databind.ObjectMapper objectMapper)
-
-
Method Details
-
handle
- Specified by:
handlein interfacecom.broadleafcommerce.common.messaging.PersistenceHandler
-
getObjectMapper
public com.fasterxml.jackson.databind.ObjectMapper getObjectMapper()- Specified by:
getObjectMapperin interfacecom.broadleafcommerce.common.messaging.PersistenceHandler
-
isValidType
- Specified by:
isValidTypein interfacecom.broadleafcommerce.common.messaging.PersistenceHandler
-
isNodeNull
public boolean isNodeNull(com.fasterxml.jackson.databind.JsonNode jsonNode) Checks if a JSON Node is equal to null or if the Node itself is present but represents the JSON literal value of "null". e.g.{ } // returns true { "name": null } // returns true { "name": "Perry" } // returns false { "name": "" } // returns false- Parameters:
jsonNode-- Returns:
- true if node is null, or JSON literal null
-