@logtape/windows-eventlog
Version:
Windows Event Log sink for LogTape
32 lines (30 loc) • 1.02 kB
TypeScript
import { WindowsEventLogSinkOptions } from "./types.js";
import { Sink } from "@logtape/logtape";
//#region sink.node.d.ts
/**
* Creates a Windows Event Log sink for Node.js environments using FFI.
*
* This implementation uses koffi to call Windows Event Log API directly,
* providing high performance logging without external dependencies.
*
* @param options Configuration options for the sink
* @returns A LogTape sink that writes to Windows Event Log
* @throws {WindowsPlatformError} If not running on Windows
* @throws {WindowsEventLogError} If Event Log operations fail
*
* @example
* ```typescript
* import { getWindowsEventLogSink } from "@logtape/windows-eventlog";
*
* const sink = getWindowsEventLogSink({
* sourceName: "MyApp"
* });
* ```
*
* @since 1.0.0
*/
declare function getWindowsEventLogSink(options: WindowsEventLogSinkOptions): Sink & Disposable;
//# sourceMappingURL=sink.node.d.ts.map
//#endregion
export { getWindowsEventLogSink };
//# sourceMappingURL=sink.node.d.ts.map