Skip to content

php-brasil/Order

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 

Repository files navigation

Domain driven order service design

<?php
use PHPBr\Order\OrderRepository;
use PHPBr\Order\OrderService;
use PHPBr\Order\Service\SimpleOrderPolicy;
use PHPBr\Order\Service\Storage\StaticStorage;

$orderRepository = new OrderRepository(new StaticStorage(),
                                       new SimpleOrderPolicy());

$orderService = new OrderService($orderRepository);

$order = $orderService->findOrder(1);

$orderService->approveOrder(1);

About

Domain driven order service design

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages