Docblock fixes

This commit is contained in:
Alex Bilbie 2014-11-07 00:46:02 +00:00
parent c38d20b163
commit 61f8195edd
2 changed files with 15 additions and 5 deletions

View File

@ -25,7 +25,7 @@ abstract class AbstractServer
/** /**
* The request object * The request object
* *
* @var Util\RequestInterface * @var \Symfony\Component\HttpFoundation\Request
*/ */
protected $request; protected $request;
@ -37,12 +37,13 @@ abstract class AbstractServer
/** /**
* Token type * Token type
* @var TokenTypeInterface * @var \League\OAuth2\Server\TokenType\TokenTypeInterface
*/ */
protected $tokenType; protected $tokenType;
/** /**
* Event emitter * Event emitter
* @var \League\Event\Emitter
*/ */
protected $eventEmitter; protected $eventEmitter;
@ -67,11 +68,20 @@ abstract class AbstractServer
} }
} }
/**
* Add an event listener to the event emitter
* @param string $eventName Event name
* @param callable $listener Callable function or method
*/
public function addEventListener($eventName, callable $listener) public function addEventListener($eventName, callable $listener)
{ {
$this->eventEmitter->addListener($eventName, $listener); $this->eventEmitter->addListener($eventName, $listener);
} }
/**
* Returns the event emitter
* @return \League\Event\Emitter
*/
public function getEventEmitter() public function getEventEmitter()
{ {
return $this->eventEmitter; return $this->eventEmitter;

View File

@ -18,11 +18,11 @@ class AccessTokenEntity extends AbstractTokenEntity
{ {
/** /**
* Get session * Get session
* @return \League\OAuth2\Server\SessionEntity * @return \League\OAuth2\Server\Entity\SessionEntity
*/ */
public function getSession() public function getSession()
{ {
if ($this->session instanceof SessionEntity) { if ($this->session instanceof Entity\SessionEntity) {
return $this->session; return $this->session;
} }
@ -47,7 +47,7 @@ class AccessTokenEntity extends AbstractTokenEntity
/** /**
* Return all scopes associated with the session * Return all scopes associated with the session
* @return array Array of \League\OAuth2\Server\Entity\Scope * @return [\League\OAuth2\Server\Entity\Scope]
*/ */
public function getScopes() public function getScopes()
{ {