package com.juick.server.component; import com.juick.User; import org.springframework.context.ApplicationEvent; public class SubscribeEvent extends ApplicationEvent { private User user; private User toUser; /** * Create a new ApplicationEvent. * * @param source the object on which the event initially occurred (never {@code null}) */ public SubscribeEvent(Object source, User user, User toUser) { super(source); this.user = user; this.toUser = toUser; } public User getUser() { return user; } public User getToUser() { return toUser; } }