logHandlerInterface.php 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. <?php
  2. /*
  3. * This program is free software; you can redistribute it and/or modify
  4. * it under the terms of the GNU General Public License as published by
  5. * the Free Software Foundation; either version 3 of the License, or
  6. * (at your option) any later version.
  7. *
  8. * This program is distributed in the hope that it will be useful,
  9. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. * GNU General Public License for more details.
  12. *
  13. * You should have received a copy of the GNU General Public License
  14. * along with this program. If not, see <https://www.gnu.org/licenses/>.
  15. * or see https://www.gnu.org/
  16. */
  17. /**
  18. * \file htdocs/core/modules/syslog/logHandlerInterface.php
  19. * \ingroup syslog
  20. * \brief LogHandlerInterface
  21. */
  22. /**
  23. * LogHandlerInterface
  24. */
  25. interface LogHandlerInterface
  26. {
  27. /**
  28. * Return name of logger
  29. *
  30. * @return string Name of logger
  31. */
  32. public function getName();
  33. /**
  34. * Return version of logger
  35. *
  36. * @return string Version of logger
  37. */
  38. public function getVersion();
  39. /**
  40. * Return information on logger
  41. *
  42. * @return string Version of logger
  43. */
  44. public function getInfo();
  45. /**
  46. * Return warning if something is wrong with logger
  47. *
  48. * @return string Warning message
  49. */
  50. public function getWarning();
  51. /**
  52. * Return array of configuration data
  53. *
  54. * @return array Return array of configuration data
  55. */
  56. public function configure();
  57. /**
  58. * Return if configuration is valid
  59. *
  60. * @return boolean True if configuration ok
  61. */
  62. public function checkConfiguration();
  63. /**
  64. * Return if logger active
  65. *
  66. * @return boolean True if active
  67. */
  68. public function isActive();
  69. /**
  70. * Output log content
  71. *
  72. * @param string $content Content to log
  73. * @return void
  74. */
  75. public function export($content);
  76. }