1 Star 1 Fork 4

神帅/ftgo-application

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
Account.java 1.09 KB
一键复制 编辑 原始数据 按行查看 历史
Chris Richardson 提交于 2017-10-23 12:40 +08:00 . Initial version of code
package net.chrisrichardson.ftgo.accountingservice.domain;
import io.eventuate.Event;
import io.eventuate.ReflectiveMutableCommandProcessingAggregate;
import io.eventuate.tram.sagas.eventsourcingsupport.SagaReplyRequestedEvent;
import java.util.Collections;
import java.util.List;
import static io.eventuate.EventUtil.events;
public class Account extends ReflectiveMutableCommandProcessingAggregate<Account, AccountCommand> {
public List<Event> process(CreateAccountCommand command) {
return events(new AccountCreatedEvent());
}
public void apply(AccountCreatedEvent event) {
}
public List<Event> process(AuthorizeCommandInternal command) {
return events(new AccountAuthorizedEvent());
}
public List<Event> process(ReverseAuthorizationCommandInternal command) {
return Collections.emptyList();
}
public List<Event> process(ReviseAuthorizationCommandInternal command) {
return Collections.emptyList();
}
public void apply(AccountAuthorizedEvent event) {
}
public void apply(SagaReplyRequestedEvent event) {
// TODO - need a way to not need this method
}
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/codergit.com/ftgo-application.git
git@gitee.com:codergit.com/ftgo-application.git
codergit.com
ftgo-application
ftgo-application
master

搜索帮助