Package pl.com.bottega.ecommerce.shipping.domain

Examples of pl.com.bottega.ecommerce.shipping.domain.Shipment


    private ShipmentRepository repository;

    @EventListener(asynchronous = true)
    public void handle(OrderSubmittedEvent event) {
        OrderDto orderDetails = orderFinder.find(event.getOrderId());
        Shipment shipment = factory.createShipment(orderDetails.getOrderId());
        repository.save(shipment);
    }
View Full Code Here


    @Inject
    private ShipmentRepository repository;

    @Override
    public Void handle(DeliverShipmentCommand command) {
        Shipment shipment = repository.load(command.getShipmentId());
        shipment.deliver();
        return null;
    }
View Full Code Here

    @Inject
    private ShipmentRepository repository;

    @Override
    public Void handle(SendShipmentCommand command) {
        Shipment shipment = repository.load(command.getShipmentId());
        shipment.ship();
        return null;
    }
View Full Code Here

TOP

Related Classes of pl.com.bottega.ecommerce.shipping.domain.Shipment

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.