org.axonframework.spring.stereotype.Aggregate.<init>()方法的使用及代码示例

x33g5p2x  于2022-01-16 转载在 其他  
字(2.4k)|赞(0)|评价(0)|浏览(119)

本文整理了Java中org.axonframework.spring.stereotype.Aggregate.<init>()方法的一些代码示例,展示了Aggregate.<init>()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Aggregate.<init>()方法的具体详情如下:
包路径:org.axonframework.spring.stereotype.Aggregate
类名称:Aggregate
方法名:<init>

Aggregate.<init>介绍

暂无

代码示例

代码示例来源:origin: AxonFramework/Axon-trader

@Aggregate
public class Company {

  @AggregateIdentifier
  private CompanyId companyId;

  @SuppressWarnings("UnusedDeclaration")
  public Company() {
    // Required by Axon Framework
  }

  @CommandHandler
  public Company(CreateCompanyCommand cmd) {
    apply(new CompanyCreatedEvent(
        cmd.getCompanyId(), cmd.getCompanyName(), cmd.getCompanyValue(), cmd.getAmountOfShares()
    ));
  }

  @CommandHandler
  public void handle(AddOrderBookToCompanyCommand cmd) {
    apply(new OrderBookAddedToCompanyEvent(companyId, cmd.getOrderBookId()));
  }

  @EventSourcingHandler
  public void on(CompanyCreatedEvent event) {
    companyId = event.getCompanyId();
  }
}

代码示例来源:origin: AxonFramework/Axon-trader

@Aggregate
public class User {

代码示例来源:origin: pivotalsoftware/ESarch

@Aggregate
public class Company {

代码示例来源:origin: holisticon/axon-kafka

@Aggregate
public class Notification {

代码示例来源:origin: AxonIQ/axon-quick-start

@Aggregate
public class ChatRoom {

代码示例来源:origin: EdisonXu/sbs-axon

@Aggregate
public class BankAccount {

代码示例来源:origin: pivotalsoftware/ESarch

@Aggregate
public class User {

代码示例来源:origin: AxonIQ/giftcard-demo

@Aggregate
@Profile("command")
public class GiftCard {

代码示例来源:origin: AxonFramework/AxonBank

@Aggregate
public class BankTransfer {

代码示例来源:origin: AxonFramework/AxonBank

@Aggregate
public class BankAccount {

代码示例来源:origin: EdisonXu/sbs-axon

@Aggregate(repository = "accountRepository")
@Entity
public class BankAccount {

代码示例来源:origin: avthart/spring-boot-axon-sample

@Aggregate
public class Task {

代码示例来源:origin: AxonFramework/Axon-trader

@Aggregate
public class Transaction {

代码示例来源:origin: pivotalsoftware/ESarch

@Aggregate
public class Transaction {

代码示例来源:origin: AxonFramework/Axon-trader

@Aggregate
public class Portfolio {

代码示例来源:origin: vvgomes/event-driven-restaurant

@Aggregate
@FieldDefaults(level = PRIVATE)
public class MenuItem {

代码示例来源:origin: vvgomes/event-driven-restaurant

@Aggregate
@FieldDefaults(level = PRIVATE)
public class Customer {

代码示例来源:origin: vvgomes/event-driven-restaurant

@Aggregate
@FieldDefaults(level = PRIVATE)
public class Order {

代码示例来源:origin: AxonFramework/Axon-trader

@Aggregate
public class OrderBook {

代码示例来源:origin: pivotalsoftware/ESarch

@Aggregate
public class OrderBook {

相关文章

Aggregate类方法