AuditManagerInterface.php 1007 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. <?php
  2. /*
  3. * This file is part of the Sonata Project 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. /**
  12. * @author Thomas Rabaix <thomas.rabaix@sonata-project.org>
  13. */
  14. interface AuditManagerInterface
  15. {
  16. /**
  17. * Set AuditReaderInterface service id for array of $classes.
  18. *
  19. * @param string $serviceId
  20. * @param array $classes
  21. */
  22. public function setReader($serviceId, array $classes);
  23. /**
  24. * Returns true if $class has AuditReaderInterface.
  25. *
  26. * @param string $class
  27. *
  28. * @return bool
  29. */
  30. public function hasReader($class);
  31. /**
  32. * Get AuditReaderInterface service for $class.
  33. *
  34. * @param string $class
  35. *
  36. * @return AuditReaderInterface
  37. *
  38. * @throws \RuntimeException
  39. */
  40. public function getReader($class);
  41. }