Update v1.0.6.5

This commit is contained in:
sujitprasad
2016-03-02 12:25:21 +05:30
parent 7011553462
commit c56ff86194
218 changed files with 17161 additions and 2358 deletions

View File

@@ -1,5 +1,14 @@
<?php
/*
* This file is part of jwt-auth.
*
* (c) Sean Tymon <tymon148@gmail.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Tymon\JWTAuth;
use Tymon\JWTAuth\Claims\Claim;
@@ -9,14 +18,14 @@ use Tymon\JWTAuth\Validators\PayloadValidator;
class Payload implements \ArrayAccess
{
/**
* The array of claims
* The array of claims.
*
* @var \Tymon\JWTAuth\Claims\Claim[]
*/
private $claims = [];
/**
* Build the Payload
* Build the Payload.
*
* @param array $claims
* @param \Tymon\JWTAuth\Validators\PayloadValidator $validator
@@ -30,7 +39,7 @@ class Payload implements \ArrayAccess
}
/**
* Get the array of claim instances
* Get the array of claim instances.
*
* @return \Tymon\JWTAuth\Claims\Claim[]
*/
@@ -40,7 +49,7 @@ class Payload implements \ArrayAccess
}
/**
* Get the array of claims
* Get the array of claims.
*
* @return array
*/
@@ -55,7 +64,7 @@ class Payload implements \ArrayAccess
}
/**
* Get the payload
* Get the payload.
*
* @param string $claim
* @return mixed
@@ -74,10 +83,10 @@ class Payload implements \ArrayAccess
}
/**
* Determine whether the payload has the claim
* Determine whether the payload has the claim.
*
* @param \Tymon\JWTAuth\Claims\Claim $claim
* @return boolean
* @return bool
*/
public function has(Claim $claim)
{
@@ -85,7 +94,7 @@ class Payload implements \ArrayAccess
}
/**
* Get the payload as a string
* Get the payload as a string.
*
* @return string
*/
@@ -117,7 +126,7 @@ class Payload implements \ArrayAccess
}
/**
* Don't allow changing the payload as it should be immutable
* Don't allow changing the payload as it should be immutable.
*
* @param mixed $key
* @param mixed $value
@@ -130,7 +139,7 @@ class Payload implements \ArrayAccess
}
/**
* Don't allow changing the payload as it should be immutable
* Don't allow changing the payload as it should be immutable.
*
* @param string $key
* @throws Exceptions\PayloadException
@@ -142,7 +151,7 @@ class Payload implements \ArrayAccess
}
/**
* Magically get a claim value
* Magically get a claim value.
*
* @param string $method
* @param array $parameters