Created
July 29, 2017 09:42
-
-
Save jeevan-patil/311ed7d87606c4a60df1aa78592c0c87 to your computer and use it in GitHub Desktop.
Generic EntityCreatedEvent class.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import org.springframework.context.ApplicationEvent; | |
public class EntityCreatedEvent<T> extends ApplicationEvent { | |
private T entity; | |
public EntityCreatedEvent(Object source, T entity) { | |
super(source); | |
this.entity = entity; | |
} | |
public T getEntity() { | |
return entity; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment