<?php
use Psr\Container\ContainerInterface as Container;

return [
  GuzzleHttp\ClientInterface::class => function(Container $c) {
    return new GuzzleHttp\Client();
  },
  ProVM\Common\Factory\Model::class => function(Container $c) {
    return new ProVM\Common\Factory\Model();
  },
  ProVM\Money\Common\Service\Update::class => function(Container $c) {
    return new ProVM\Money\Common\Service\Update($c->get(ProVM\Common\Factory\Model::class), $c->get(GuzzleHttp\ClientInterface::class));
  },
  ProVM\Money\Common\Middleware\Migrate::class => function(Container $c) {
    return new ProVM\Money\Common\Middleware\Migrate($c->get(Phinx\Wrapper\TextWrapper::class), $c->get(ProVM\Money\Common\Service\Update::class));
  },
  Phinx\Console\PhinxApplication::class => function(Container $c) {
    return new Phinx\Console\PhinxApplication();
  },
  Phinx\Wrapper\TextWrapper::class => function(Container $c) {
    $options = [
      'configuration' => $c->get('phinx')
    ];
    return new Phinx\Wrapper\TextWrapper($c->get(Phinx\Console\PhinxApplication::class), $options);
  }
];
