Frontier
In memory implementation of a frontier
Constructor Summary
Public Constructor | ||
public |
Create a new frontier object |
Member Summary
Public Members | ||
public |
Information pertaining to the current URL being crawled |
|
public |
queue: {url: string, mode: Symbol, cdepth: number, tracker: string}}[] URLs to be crawled |
|
public |
Tracks the depth and crawl config per starting seed |
Method Summary
Public Methods | ||
public |
Is the frontier exhausted |
|
public |
init(starting: Seed[] | Seed) Initialize the initial frontier |
|
public |
Get the next URL to crawl from the frontier, queue length - 1 |
|
public |
Process discovered outlinks of a page based on the originating seeds configuration |
|
public |
Returns the number of URLs left in the queue |
Public Constructors
Public Members
public current: {url: string, mode: Symbol, cdepth: number, tracker: string} source
Information pertaining to the current URL being crawled
public queue: {url: string, mode: Symbol, cdepth: number, tracker: string}}[] source
URLs to be crawled
public trackers: Map<string, SeedTracker> source
Tracks the depth and crawl config per starting seed
Public Methods
public init(starting: Seed[] | Seed) source
Initialize the initial frontier
Params:
Name | Type | Attribute | Description |
starting | Seed[] | Seed |