stream_creator.cpp 987 B

1234567891011121314151617181920212223242526272829303132
  1. #include "stream_creator.h"
  2. #include "stream.h"
  3. THolder<TLogBackend> TCerrLogBackendCreator::DoCreateLogBackend() const {
  4. return MakeHolder<TStreamLogBackend>(&Cerr);
  5. }
  6. TCerrLogBackendCreator::TCerrLogBackendCreator()
  7. : TLogBackendCreatorBase("cerr")
  8. {}
  9. void TCerrLogBackendCreator::DoToJson(NJson::TJsonValue& /*value*/) const {
  10. }
  11. ILogBackendCreator::TFactory::TRegistrator<TCerrLogBackendCreator> TCerrLogBackendCreator::RegistrarCerr("cerr");
  12. ILogBackendCreator::TFactory::TRegistrator<TCerrLogBackendCreator> TCerrLogBackendCreator::RegistrarConsole("console");
  13. THolder<TLogBackend> TCoutLogBackendCreator::DoCreateLogBackend() const {
  14. return MakeHolder<TStreamLogBackend>(&Cout);
  15. }
  16. TCoutLogBackendCreator::TCoutLogBackendCreator()
  17. : TLogBackendCreatorBase("cout")
  18. {}
  19. ILogBackendCreator::TFactory::TRegistrator<TCoutLogBackendCreator> TCoutLogBackendCreator::Registrar("cout");
  20. void TCoutLogBackendCreator::DoToJson(NJson::TJsonValue& /*value*/) const {
  21. }