AuditManagerInterface.php 957 B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. <?php
  2. /*
  3. * This file is part of the Sonata package.
  4. *
  5. * (c) Thomas Rabaix <thomas.rabaix@sonata-project.org>
  6. *
  7. * For the full copyright and license information, please view the LICENSE
  8. * file that was distributed with this source code.
  9. */
  10. namespace Sonata\AdminBundle\Model;
  11. interface AuditManagerInterface
  12. {
  13. /**
  14. * Set AuditReaderInterface service id for array of $classes.
  15. *
  16. * @param string $serviceId
  17. * @param array $classes
  18. */
  19. public function setReader($serviceId, array $classes);
  20. /**
  21. * Returns true if $class has AuditReaderInterface.
  22. *
  23. * @param string $class
  24. *
  25. * @return bool
  26. */
  27. public function hasReader($class);
  28. /**
  29. * Get AuditReaderInterface service for $class.
  30. *
  31. * @param string $class
  32. *
  33. * @return \Sonata\AdminBundle\Model\AuditReaderInterface
  34. *
  35. * @throws \RuntimeException
  36. */
  37. public function getReader($class);
  38. }