Skip to content

Commit

Permalink
Move providers to module dir. #588
Browse files Browse the repository at this point in the history
  • Loading branch information
overtrue committed Feb 10, 2017
1 parent dec4a38 commit 861c4a9
Show file tree
Hide file tree
Showing 22 changed files with 105 additions and 134 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
*/

/**
* BroadcastServiceProvider.php.
* ServiceProvider.php.
*
* This file is part of the wechat.
*
Expand All @@ -20,16 +20,15 @@
* with this source code in the file LICENSE.
*/

namespace EasyWeChat\Foundation\ServiceProviders;
namespace EasyWeChat\Broadcast;

use EasyWeChat\Broadcast\Broadcast;
use Pimple\Container;
use Pimple\ServiceProviderInterface;

/**
* Class BroadcastServiceProvider.
* Class ServiceProvider.
*/
class BroadcastServiceProvider implements ServiceProviderInterface
class ServiceProvider implements ServiceProviderInterface
{
/**
* Registers services on the given container.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
*/

/**
* JsServiceProvider.php.
* ServiceProvider.php.
*
* This file is part of the wechat.
*
Expand All @@ -20,16 +20,15 @@
* with this source code in the file LICENSE.
*/

namespace EasyWeChat\Foundation\ServiceProviders;
namespace EasyWeChat\Card;

use EasyWeChat\Card\Card;
use Pimple\Container;
use Pimple\ServiceProviderInterface;

/**
* Class JsServiceProvider.
* Class ServiceProvider.
*/
class CardServiceProvider implements ServiceProviderInterface
class ServiceProvider implements ServiceProviderInterface
{
/**
* Registers services on the given container.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
*/

/**
* QRCodeServiceProvider.php.
* ServiceProvider.php.
*
* Part of Overtrue\WeChat.
*
Expand All @@ -24,16 +24,15 @@
* @see http://overtrue.me
*/

namespace EasyWeChat\Foundation\ServiceProviders;
namespace EasyWeChat\Device;

use EasyWeChat\Device\Device;
use Pimple\Container;
use Pimple\ServiceProviderInterface;

/**
* Class DeviceServiceProvider.
* Class ServiceProvider.
*/
class DeviceServiceProvider implements ServiceProviderInterface
class ServiceProvider implements ServiceProviderInterface
{
/**
* Registers services on the given container.
Expand Down
42 changes: 21 additions & 21 deletions src/Foundation/Application.php
Original file line number Diff line number Diff line change
Expand Up @@ -77,27 +77,27 @@ class Application extends Container
* @var array
*/
protected $providers = [
ServiceProviders\ServerServiceProvider::class,
ServiceProviders\UserServiceProvider::class,
ServiceProviders\JsServiceProvider::class,
ServiceProviders\OAuthServiceProvider::class,
ServiceProviders\MenuServiceProvider::class,
ServiceProviders\NoticeServiceProvider::class,
ServiceProviders\MaterialServiceProvider::class,
ServiceProviders\StaffServiceProvider::class,
ServiceProviders\UrlServiceProvider::class,
ServiceProviders\QRCodeServiceProvider::class,
ServiceProviders\SemanticServiceProvider::class,
ServiceProviders\StatsServiceProvider::class,
ServiceProviders\PaymentServiceProvider::class,
ServiceProviders\POIServiceProvider::class,
ServiceProviders\ReplyServiceProvider::class,
ServiceProviders\BroadcastServiceProvider::class,
ServiceProviders\CardServiceProvider::class,
ServiceProviders\DeviceServiceProvider::class,
ServiceProviders\ShakeAroundServiceProvider::class,
ServiceProviders\OpenPlatformServiceProvider::class,
ServiceProviders\MiniProgramServiceProvider::class,
\EasyWeChat\Server\ServiceProvider::class,
\EasyWeChat\User\ServiceProvider::class,
\EasyWeChat\Js\ServiceProvider::class,
\EasyWeChat\OAuth\ServiceProvider::class,
\EasyWeChat\Menu\ServiceProvider::class,
\EasyWeChat\Notice\ServiceProvider::class,
\EasyWeChat\Material\ServiceProvider::class,
\EasyWeChat\Staff\ServiceProvider::class,
\EasyWeChat\Url\ServiceProvider::class,
\EasyWeChat\QRCode\ServiceProvider::class,
\EasyWeChat\Semantic\ServiceProvider::class,
\EasyWeChat\Stats\ServiceProvider::class,
\EasyWeChat\Payment\ServiceProvider::class,
\EasyWeChat\POI\ServiceProvider::class,
\EasyWeChat\Reply\ServiceProvider::class,
\EasyWeChat\Broadcast\ServiceProvider::class,
\EasyWeChat\Card\ServiceProvider::class,
\EasyWeChat\Device\ServiceProvider::class,
\EasyWeChat\ShakeAround\ServiceProvider::class,
\EasyWeChat\OpenPlatform\ServiceProvider::class,
\EasyWeChat\MiniProgram\ServiceProvider::class,
];

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
*/

/**
* JsServiceProvider.php.
* ServiceProvider.php.
*
* This file is part of the wechat.
*
Expand All @@ -20,16 +20,15 @@
* with this source code in the file LICENSE.
*/

namespace EasyWeChat\Foundation\ServiceProviders;
namespace EasyWeChat\Js;

use EasyWeChat\Js\Js;
use Pimple\Container;
use Pimple\ServiceProviderInterface;

/**
* Class JsServiceProvider.
* Class ServiceProvider.
*/
class JsServiceProvider implements ServiceProviderInterface
class ServiceProvider implements ServiceProviderInterface
{
/**
* Registers services on the given container.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
*/

/**
* MaterialServiceProvider.php.
* ServiceProvider.php.
*
* This file is part of the wechat.
*
Expand All @@ -20,17 +20,15 @@
* with this source code in the file LICENSE.
*/

namespace EasyWeChat\Foundation\ServiceProviders;
namespace EasyWeChat\Material;

use EasyWeChat\Material\Material;
use EasyWeChat\Material\Temporary;
use Pimple\Container;
use Pimple\ServiceProviderInterface;

/**
* Class MaterialServiceProvider.
* Class ServiceProvider.
*/
class MaterialServiceProvider implements ServiceProviderInterface
class ServiceProvider implements ServiceProviderInterface
{
/**
* Registers services on the given container.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
*/

/**
* MenuServiceProvider.php.
* ServiceProvider.php.
*
* This file is part of the wechat.
*
Expand All @@ -20,16 +20,15 @@
* with this source code in the file LICENSE.
*/

namespace EasyWeChat\Foundation\ServiceProviders;
namespace EasyWeChat\Menu;

use EasyWeChat\Menu\Menu;
use Pimple\Container;
use Pimple\ServiceProviderInterface;

/**
* Class MenuServiceProvider.
* Class ServiceProvider.
*/
class MenuServiceProvider implements ServiceProviderInterface
class ServiceProvider implements ServiceProviderInterface
{
/**
* Registers services on the given container.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
*/

/**
* MiniProgramServiceProvider.php.
* ServiceProvider.php.
*
* This file is part of the wechat.
*
Expand All @@ -20,19 +20,17 @@
* with this source code in the file LICENSE.
*/

namespace EasyWeChat\Foundation\ServiceProviders;
namespace EasyWeChat\MiniProgram;

use EasyWeChat\Encryption\Encryptor;
use EasyWeChat\MiniProgram\AccessToken;
use EasyWeChat\MiniProgram\MiniProgram;
use EasyWeChat\MiniProgram\Server\Guard;
use Pimple\Container;
use Pimple\ServiceProviderInterface;

/**
* Class MiniProgramServiceProvider.
* Class ServiceProvider.
*/
class MiniProgramServiceProvider implements ServiceProviderInterface
class ServiceProvider implements ServiceProviderInterface
{
/**
* Registers services on the given container.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
*/

/**
* NoticeServiceProvider.php.
* ServiceProvider.php.
*
* This file is part of the wechat.
*
Expand All @@ -20,16 +20,15 @@
* with this source code in the file LICENSE.
*/

namespace EasyWeChat\Foundation\ServiceProviders;
namespace EasyWeChat\Notice;

use EasyWeChat\Notice\Notice;
use Pimple\Container;
use Pimple\ServiceProviderInterface;

/**
* Class NoticeServiceProvider.
* Class ServiceProvider.
*/
class NoticeServiceProvider implements ServiceProviderInterface
class ServiceProvider implements ServiceProviderInterface
{
/**
* Registers services on the given container.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
*/

/**
* OAuthServiceProvider.php.
* ServiceProvider.php.
*
* This file is part of the wechat.
*
Expand All @@ -20,16 +20,16 @@
* with this source code in the file LICENSE.
*/

namespace EasyWeChat\Foundation\ServiceProviders;
namespace EasyWeChat\OAuth;

use Overtrue\Socialite\SocialiteManager as Socialite;
use Pimple\Container;
use Pimple\ServiceProviderInterface;

/**
* Class OAuthServiceProvider.
* Class ServiceProvider.
*/
class OAuthServiceProvider implements ServiceProviderInterface
class ServiceProvider implements ServiceProviderInterface
{
/**
* Registers services on the given container.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
*/

/**
* OpenPlatformServiceProvider.php.
* ServiceProvider.php.
*
* This file is part of the wechat.
*
Expand All @@ -20,20 +20,16 @@
* with this source code in the file LICENSE.
*/

namespace EasyWeChat\Foundation\ServiceProviders;
namespace EasyWeChat\OpenPlatform;

use EasyWeChat\Encryption\Encryptor;
use EasyWeChat\OpenPlatform\AccessToken;
use EasyWeChat\OpenPlatform\Guard;
use EasyWeChat\OpenPlatform\OpenPlatform;
use EasyWeChat\OpenPlatform\VerifyTicket;
use Pimple\Container;
use Pimple\ServiceProviderInterface;

/**
* Class OpenPlatformServiceProvider.
* Class ServiceProvider.
*/
class OpenPlatformServiceProvider implements ServiceProviderInterface
class ServiceProvider implements ServiceProviderInterface
{
/**
* Registers services on the given container.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
*/

/**
* POIServiceProvider.php.
* ServiceProvider.php.
*
* Part of Overtrue\WeChat.
*
Expand All @@ -24,16 +24,15 @@
* @see http://overtrue.me
*/

namespace EasyWeChat\Foundation\ServiceProviders;
namespace EasyWeChat\POI;

use EasyWeChat\POI\POI;
use Pimple\Container;
use Pimple\ServiceProviderInterface;

/**
* Class POIServiceProvider.
* Class ServiceProvider.
*/
class POIServiceProvider implements ServiceProviderInterface
class ServiceProvider implements ServiceProviderInterface
{
/**
* Registers services on the given container.
Expand Down
Loading

0 comments on commit 861c4a9

Please sign in to comment.