catalog.js
Version:
A JavaScript / TypeScript API for the Middlebury course catalog.
26 lines • 771 B
TypeScript
import Catalog from "./Catalog.js";
/**
* A scraper class to scrape the data from the course page
*
*/
export default class Scraper {
catalog: Catalog;
raw: string;
href: string;
term: string;
searchParameters: object[];
constructor(obj: {
term?: string | null;
searchParameters?: object[] | null;
filepath?: string | null;
});
private _convertTerm;
getCatalog(): Promise<Catalog>;
getCatalogFromFile(filepath: string): Promise<Catalog>;
scrapeFromFile(filepath: string): Promise<Scraper>;
parseFromFile(filepath: string): Promise<Scraper>;
scrape(): Promise<Scraper>;
parse(): Promise<Scraper>;
private _getScraperURL;
}
//# sourceMappingURL=Scraper.d.ts.map