Home Reference Source
import ElectronWARCGenerator from 'node-warc/lib/writers/electron.js'
public class | source

ElectronWARCGenerator

Extends:

WARCWriterBase → ElectronWARCGenerator

WARC Generator for use with Electron

See:

Method Summary

Public Methods
public

async generateWARC(capturer: ElectronRequestCapturer, wcDebugger: Object, genOpts: WARCGenOpts): Promise<void>

public

async generateWarcEntry(nreq: CDPRequestInfo, wcDebugger: Object): Promise<void>

Generate a WARC record

Public Methods

public async generateWARC(capturer: ElectronRequestCapturer, wcDebugger: Object, genOpts: WARCGenOpts): Promise<void> source

Params:

NameTypeAttributeDescription
capturer ElectronRequestCapturer

The Electron request capturer that contains requests to be serialized to the WARC

wcDebugger Object

the Electron debugger to use to get the response body

genOpts WARCGenOpts

Options for generating the WARC and optionally generating WARC info, WARC info + Webrecorder Player bookmark list, metadata records

Return:

Promise<void>

A Promise that resolves when WARC generation is complete

public async generateWarcEntry(nreq: CDPRequestInfo, wcDebugger: Object): Promise<void> source

Generate a WARC record

Params:

NameTypeAttributeDescription
nreq CDPRequestInfo

The captured HTTP info

wcDebugger Object

The Electron webcontents debugger object

Return:

Promise<void>