1 | import IterResult, { IterArgs } from './iterresult';
|
2 | import { Language } from './nlp/i18n';
|
3 | import { DateFormatter, GetText } from './nlp/totext';
|
4 | import { ParsedOptions, Options, Frequency, QueryMethods, QueryMethodTypes, IterResultType } from './types';
|
5 | import { parseString } from './parsestring';
|
6 | import { optionsToString } from './optionstostring';
|
7 | import { Cache, CacheKeys } from './cache';
|
8 | import { Weekday } from './weekday';
|
9 | export declare const Days: {
|
10 | MO: Weekday;
|
11 | TU: Weekday;
|
12 | WE: Weekday;
|
13 | TH: Weekday;
|
14 | FR: Weekday;
|
15 | SA: Weekday;
|
16 | SU: Weekday;
|
17 | };
|
18 | export declare const DEFAULT_OPTIONS: Options;
|
19 | export declare const defaultKeys: (keyof Options)[];
|
20 |
|
21 |
|
22 |
|
23 |
|
24 |
|
25 |
|
26 | export declare class RRule implements QueryMethods {
|
27 | _cache: Cache | null;
|
28 | origOptions: Partial<Options>;
|
29 | options: ParsedOptions;
|
30 | static readonly FREQUENCIES: (keyof typeof Frequency)[];
|
31 | static readonly YEARLY = Frequency.YEARLY;
|
32 | static readonly MONTHLY = Frequency.MONTHLY;
|
33 | static readonly WEEKLY = Frequency.WEEKLY;
|
34 | static readonly DAILY = Frequency.DAILY;
|
35 | static readonly HOURLY = Frequency.HOURLY;
|
36 | static readonly MINUTELY = Frequency.MINUTELY;
|
37 | static readonly SECONDLY = Frequency.SECONDLY;
|
38 | static readonly MO: Weekday;
|
39 | static readonly TU: Weekday;
|
40 | static readonly WE: Weekday;
|
41 | static readonly TH: Weekday;
|
42 | static readonly FR: Weekday;
|
43 | static readonly SA: Weekday;
|
44 | static readonly SU: Weekday;
|
45 | constructor(options?: Partial<Options>, noCache?: boolean);
|
46 | static parseText(text: string, language?: Language): Partial<Options>;
|
47 | static fromText(text: string, language?: Language): RRule;
|
48 | static parseString: typeof parseString;
|
49 | static fromString(str: string): RRule;
|
50 | static optionsToString: typeof optionsToString;
|
51 | protected _iter<M extends QueryMethodTypes>(iterResult: IterResult<M>): IterResultType<M>;
|
52 | private _cacheGet;
|
53 | _cacheAdd(what: CacheKeys | 'all', value: Date[] | Date | null, args?: Partial<IterArgs>): void;
|
54 | /**
|
55 | * @param {Function} iterator - optional function that will be called
|
56 | * on each date that is added. It can return false
|
57 | * to stop the iteration.
|
58 | * @return Array containing all recurrences.
|
59 | */
|
60 | all(iterator?: (d: Date, len: number) => boolean): Date[];
|
61 | |
62 |
|
63 |
|
64 |
|
65 |
|
66 |
|
67 |
|
68 |
|
69 | between(after: Date, before: Date, inc?: boolean, iterator?: (d: Date, len: number) => boolean): Date[];
|
70 | |
71 |
|
72 |
|
73 |
|
74 |
|
75 |
|
76 |
|
77 | before(dt: Date, inc?: boolean): Date | null;
|
78 | |
79 |
|
80 |
|
81 |
|
82 |
|
83 |
|
84 |
|
85 | after(dt: Date, inc?: boolean): Date | null;
|
86 | |
87 |
|
88 |
|
89 |
|
90 | count(): number;
|
91 | |
92 |
|
93 |
|
94 |
|
95 |
|
96 |
|
97 | toString(): string;
|
98 | |
99 |
|
100 |
|
101 |
|
102 | toText(gettext?: GetText, language?: Language, dateFormatter?: DateFormatter): string;
|
103 | isFullyConvertibleToText(): boolean;
|
104 | |
105 |
|
106 |
|
107 |
|
108 | clone(): RRule;
|
109 | }
|
110 |
|
\ | No newline at end of file |