basicconfigurator.h 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. /******************************************************************************
  2. *
  3. * package: Log4Qt
  4. * file: basicconfigurator.h
  5. * created: September 2007
  6. * author: Martin Heinrich
  7. *
  8. *
  9. * Copyright 2007 Martin Heinrich
  10. *
  11. * Licensed under the Apache License, Version 2.0 (the "License");
  12. * you may not use this file except in compliance with the License.
  13. * You may obtain a copy of the License at
  14. *
  15. * http://www.apache.org/licenses/LICENSE-2.0
  16. *
  17. * Unless required by applicable law or agreed to in writing, software
  18. * distributed under the License is distributed on an "AS IS" BASIS,
  19. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  20. * See the License for the specific language governing permissions and
  21. * limitations under the License.
  22. *
  23. ******************************************************************************/
  24. #ifndef LOG4QT_BASICCONFIGURATOR_H
  25. #define LOG4QT_BASICCONFIGURATOR_H
  26. /******************************************************************************
  27. * Dependencies
  28. ******************************************************************************/
  29. #include <QtCore/Qt>
  30. #include "log4qt/log4qt.h"
  31. /******************************************************************************
  32. * Declarations
  33. ******************************************************************************/
  34. namespace Log4Qt
  35. {
  36. class Appender;
  37. /*!
  38. * \brief The class BasicConfigurator provides a simple package
  39. * configuration.
  40. *
  41. * \note All the functions declared in this class are thread-safe.
  42. */
  43. class BasicConfigurator
  44. {
  45. private:
  46. BasicConfigurator(); // Not implemented
  47. // BasicConfigurator(const BasicConfigurator &rOther); // Use compiler default
  48. // virtual ~BasicConfigurator(); // Use compiler default
  49. // BasicConfigurator &operator=(const BasicConfigurator &rOther); // Use compiler default
  50. public:
  51. static bool configure();
  52. static void configure(Appender *pAppender);
  53. static void resetConfiguration();
  54. };
  55. /**************************************************************************
  56. * Operators, Helper
  57. **************************************************************************/
  58. /**************************************************************************
  59. * Inline
  60. **************************************************************************/
  61. } // namspace Log4Qt
  62. // Q_DECLARE_TYPEINFO(Log4Qt::BasicConfigurator, Q_MOVABLE_TYPE); // Use default
  63. #endif // LOG4QT_BASICCONFIGURATOR_H