Auth.php 810 B

123456789101112131415161718192021222324252627282930313233
  1. <?php
  2. /**
  3. * Authentication provider interface
  4. *
  5. * @package Requests
  6. * @subpackage Authentication
  7. */
  8. /**
  9. * Authentication provider interface
  10. *
  11. * Implement this interface to act as an authentication provider.
  12. *
  13. * Parameters should be passed via the constructor where possible, as this
  14. * makes it much easier for users to use your provider.
  15. *
  16. * @see Requests_Hooks
  17. * @package Requests
  18. * @subpackage Authentication
  19. */
  20. interface Requests_Auth {
  21. /**
  22. * Register hooks as needed
  23. *
  24. * This method is called in {@see Requests::request} when the user has set
  25. * an instance as the 'auth' option. Use this callback to register all the
  26. * hooks you'll need.
  27. *
  28. * @see Requests_Hooks::register
  29. * @param Requests_Hooks $hooks Hook system
  30. */
  31. public function register(Requests_Hooks &$hooks);
  32. }