for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* @author Boris Guéry <[email protected]>
*/
namespace Bgy\OAuth2;
class AccessTokenFactory
{
private $generator;
public function __construct(AccessTokenGenerator $generator)
$this->generator = $generator;
}
public function createAccessToken($expiresIn, $clientId, $resourceOwnerId, array $scopes = [])
return new AccessToken(
$this->generator->generate(),
$expiresIn,
$clientId,
$resourceOwnerId,
$scopes
);