public class PlatformEventListener extends Object implements org.springframework.context.ApplicationContextAware
PlatformEvent
on PrePersist
, PreUpdate
and
PreRemove
. Also, a PlatformEvent
can be created manually by calling
#createEvent(Type, String)
. ApplicationContext
to
retrieve an instance of the EntityManager
in use.Modifier and Type | Class and Description |
---|---|
static class |
PlatformEventListener.EventProvider |
Constructor and Description |
---|
PlatformEventListener() |
Modifier and Type | Method and Description |
---|---|
void |
beforeCreate(Auditable<?> o) |
void |
createEvent(PlatformEvent.Type type,
String message) |
void |
createEvent(PlatformEvent.Type type,
String message,
javax.servlet.http.HttpSession session) |
PlatformEventListener.EventProvider |
getEventProvider() |
void |
onDelete(Auditable<?> o) |
void |
onUpdate(Auditable<?> o) |
void |
setApplicationContext(org.springframework.context.ApplicationContext applicationContext) |
void |
setAuditApplication(String auditApplication) |
void |
setAuditUser(String auditUser) |
void |
setEventProvider(PlatformEventListener.EventProvider eventProvider) |
void |
setPersist(boolean persist) |
public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext) throws org.springframework.beans.BeansException
setApplicationContext
in interface org.springframework.context.ApplicationContextAware
org.springframework.beans.BeansException
public void beforeCreate(Auditable<?> o)
public void onUpdate(Auditable<?> o)
public void onDelete(Auditable<?> o)
public void createEvent(PlatformEvent.Type type, String message)
public void createEvent(PlatformEvent.Type type, String message, javax.servlet.http.HttpSession session)
public void setAuditUser(String auditUser)
public void setAuditApplication(String auditApplication)
public void setPersist(boolean persist)
public PlatformEventListener.EventProvider getEventProvider()
public void setEventProvider(PlatformEventListener.EventProvider eventProvider)
Copyright © 2011–2019 aiticon GmbH. All rights reserved.