Claim.php 733 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. <?php
  2. /**
  3. * This file is part of Lcobucci\JWT, a simple library to handle JWT and JWS
  4. *
  5. * @license http://opensource.org/licenses/BSD-3-Clause BSD-3-Clause
  6. */
  7. namespace Lcobucci\JWT;
  8. use JsonSerializable;
  9. /**
  10. * Basic interface for token claims
  11. *
  12. * @author Luís Otávio Cobucci Oblonczyk <lcobucci@gmail.com>
  13. * @since 2.0.0
  14. */
  15. interface Claim extends JsonSerializable
  16. {
  17. /**
  18. * Returns the claim name
  19. *
  20. * @return string
  21. */
  22. public function getName();
  23. /**
  24. * Returns the claim value
  25. *
  26. * @return string
  27. */
  28. public function getValue();
  29. /**
  30. * Returns the string representation of the claim
  31. *
  32. * @return string
  33. */
  34. public function __toString();
  35. }