logging: Add DebuggerBackend for logging to Visual Studio
This commit is contained in:
parent
9c904e475b
commit
3d083859c1
4 changed files with 29 additions and 2 deletions
|
@ -105,6 +105,20 @@ private:
|
|||
std::size_t bytes_written;
|
||||
};
|
||||
|
||||
/**
|
||||
* Backend that writes to Visual Studio's output window
|
||||
*/
|
||||
class DebuggerBackend : public Backend {
|
||||
public:
|
||||
static const char* Name() {
|
||||
return "debugger";
|
||||
}
|
||||
const char* GetName() const override {
|
||||
return Name();
|
||||
}
|
||||
void Write(const Entry& entry) override;
|
||||
};
|
||||
|
||||
void AddBackend(std::unique_ptr<Backend> backend);
|
||||
|
||||
void RemoveBackend(std::string_view backend_name);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue