import { FeedEntry } from "./feed_entry"; import { FeedStore } from "./feed_store"; /** * Stores feed data to a sheet of Google Spreadsheet. * The first row is used for an marker and metadata. * The feeds are stored to second or later rows. */ export declare class SpreadsheetStore implements FeedStore { readonly spreadsheetId: string; readonly sheetName: string; static readonly ETAG_POSITION = 3; private static readonly FEED_MARK; private static readonly DATA_VERSION; private readonly sheet; /** * Create a new SpreadsheetStore. * * @param spreadsheetId - An ID of spreadsheet. * @param sheetName - A name of sheet. */ constructor(spreadsheetId: string, sheetName: string); /** * Load stored ETag data. * Returns an empty string when there is no stored data. * * @returns ETag. */ loadETag(): string; /** * Save the ETag data. * * @param etag - ETag. */ saveETag(etag: string): void; /** * Get the feed count of store. * * @returns feed count. */ getFeedCount(): number; /** * Load the latest n feeds. * * @param n - Count of feeds. * @returns Loaded feeds. */ loadFeeds(n: number): FeedEntry[]; /** * Save new feeds. * This does not care the feed's ID. * Always stored all feeds. * * @param feeds - Feeds to save. */ saveFeeds(feeds: FeedEntry[]): void; /** * Return true if there is no feeds in this store. * * @returns Store is empty or not. */ isEmpty(): boolean; /** * Clear all stored feeds. */ clear(): void; private initialize; private isInitialized; private getSheet; }