linqx 0.2.1 → 0.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (144) hide show
  1. package/README.md +79 -3
  2. package/dist/core/dictionary.d.ts +14 -0
  3. package/dist/core/enumerable.d.ts +9 -0
  4. package/dist/core/enumerator.d.ts +10 -0
  5. package/dist/core/grouping.d.ts +11 -0
  6. package/dist/core/lookup.d.ts +12 -0
  7. package/dist/core/memoized-enumerable.d.ts +12 -0
  8. package/dist/core/ordered-enumerable.d.ts +14 -0
  9. package/dist/core/shared-enumerable.d.ts +10 -0
  10. package/dist/extensions.d.ts +18 -0
  11. package/dist/extensions.js +13 -0
  12. package/dist/factories/choice.d.ts +8 -0
  13. package/dist/factories/cycle.d.ts +8 -0
  14. package/dist/factories/defer.d.ts +8 -0
  15. package/dist/factories/empty.d.ts +3 -0
  16. package/dist/factories/from.d.ts +46 -0
  17. package/dist/factories/generate.d.ts +9 -0
  18. package/dist/factories/make.d.ts +8 -0
  19. package/dist/factories/matches.d.ts +14 -0
  20. package/dist/factories/range-down.d.ts +10 -0
  21. package/dist/factories/range-to.d.ts +12 -0
  22. package/dist/factories/range.d.ts +10 -0
  23. package/dist/factories/repeat-with-finalize.d.ts +9 -0
  24. package/dist/factories/repeat.d.ts +9 -0
  25. package/dist/factories/to-infinity.d.ts +9 -0
  26. package/dist/factories/to-negative-infinity.d.ts +9 -0
  27. package/dist/factories/unfold.d.ts +9 -0
  28. package/dist/index.d.ts +87 -3
  29. package/dist/index.js +2 -4
  30. package/dist/internal/create-enumerable.d.ts +3 -0
  31. package/dist/internal/functions.d.ts +6 -0
  32. package/dist/internal/to-iterable.d.ts +2 -0
  33. package/dist/operators/aggregate-by.d.ts +2 -0
  34. package/dist/operators/aggregate.d.ts +2 -0
  35. package/dist/operators/all.d.ts +2 -0
  36. package/dist/operators/alternate.d.ts +2 -0
  37. package/dist/operators/any.d.ts +2 -0
  38. package/dist/operators/append.d.ts +2 -0
  39. package/dist/operators/as-enumerable.d.ts +2 -0
  40. package/dist/operators/average.d.ts +2 -0
  41. package/dist/operators/buffer.d.ts +2 -0
  42. package/dist/operators/cast.d.ts +2 -0
  43. package/dist/operators/catch-error.d.ts +2 -0
  44. package/dist/operators/choose.d.ts +2 -0
  45. package/dist/operators/chunk.d.ts +2 -0
  46. package/dist/operators/concat.d.ts +2 -0
  47. package/dist/operators/contains.d.ts +2 -0
  48. package/dist/operators/count-by.d.ts +2 -0
  49. package/dist/operators/count.d.ts +2 -0
  50. package/dist/operators/create-ordered-enumerable.d.ts +2 -0
  51. package/dist/operators/default-if-empty.d.ts +2 -0
  52. package/dist/operators/distinct-by.d.ts +2 -0
  53. package/dist/operators/distinct-until-changed.d.ts +2 -0
  54. package/dist/operators/distinct.d.ts +2 -0
  55. package/dist/operators/do-action.d.ts +3 -0
  56. package/dist/operators/element-at-or-default.d.ts +2 -0
  57. package/dist/operators/element-at.d.ts +2 -0
  58. package/dist/operators/except-by.d.ts +2 -0
  59. package/dist/operators/except.d.ts +2 -0
  60. package/dist/operators/finally-action.d.ts +2 -0
  61. package/dist/operators/first-or-default.d.ts +2 -0
  62. package/dist/operators/first.d.ts +2 -0
  63. package/dist/operators/flatten.d.ts +2 -0
  64. package/dist/operators/for-each.d.ts +3 -0
  65. package/dist/operators/force.d.ts +2 -0
  66. package/dist/operators/group-by.d.ts +2 -0
  67. package/dist/operators/group-join.d.ts +2 -0
  68. package/dist/operators/index-of.d.ts +2 -0
  69. package/dist/operators/index.d.ts +2 -0
  70. package/dist/operators/insert.d.ts +2 -0
  71. package/dist/operators/intersect-by.d.ts +2 -0
  72. package/dist/operators/intersect.d.ts +2 -0
  73. package/dist/operators/is-empty.d.ts +2 -0
  74. package/dist/operators/join-with.d.ts +2 -0
  75. package/dist/operators/join.d.ts +2 -0
  76. package/dist/operators/last-index-of.d.ts +2 -0
  77. package/dist/operators/last-or-default.d.ts +2 -0
  78. package/dist/operators/last.d.ts +2 -0
  79. package/dist/operators/left-join.d.ts +2 -0
  80. package/dist/operators/let-bind.d.ts +2 -0
  81. package/dist/operators/log.d.ts +2 -0
  82. package/dist/operators/map.d.ts +2 -0
  83. package/dist/operators/max-by.d.ts +2 -0
  84. package/dist/operators/max.d.ts +2 -0
  85. package/dist/operators/memoize.d.ts +2 -0
  86. package/dist/operators/merge.d.ts +2 -0
  87. package/dist/operators/min-by.d.ts +2 -0
  88. package/dist/operators/min.d.ts +2 -0
  89. package/dist/operators/of-type.d.ts +2 -0
  90. package/dist/operators/operators.d.ts +208 -0
  91. package/dist/operators/order-by-descending.d.ts +2 -0
  92. package/dist/operators/order-by.d.ts +2 -0
  93. package/dist/operators/page.d.ts +2 -0
  94. package/dist/operators/pairwise.d.ts +2 -0
  95. package/dist/operators/partition-by.d.ts +2 -0
  96. package/dist/operators/position.d.ts +2 -0
  97. package/dist/operators/prepend.d.ts +2 -0
  98. package/dist/operators/reverse.d.ts +2 -0
  99. package/dist/operators/right-join.d.ts +2 -0
  100. package/dist/operators/scan.d.ts +2 -0
  101. package/dist/operators/select-many.d.ts +2 -0
  102. package/dist/operators/select.d.ts +2 -0
  103. package/dist/operators/sequence-equal.d.ts +2 -0
  104. package/dist/operators/share.d.ts +2 -0
  105. package/dist/operators/shuffle.d.ts +2 -0
  106. package/dist/operators/single-or-default.d.ts +2 -0
  107. package/dist/operators/single.d.ts +2 -0
  108. package/dist/operators/skip-last.d.ts +2 -0
  109. package/dist/operators/skip-while.d.ts +2 -0
  110. package/dist/operators/skip.d.ts +2 -0
  111. package/dist/operators/sum.d.ts +2 -0
  112. package/dist/operators/take-except-last.d.ts +2 -0
  113. package/dist/operators/take-from-last.d.ts +2 -0
  114. package/dist/operators/take-last.d.ts +2 -0
  115. package/dist/operators/take-while.d.ts +2 -0
  116. package/dist/operators/take.d.ts +2 -0
  117. package/dist/operators/then-by-descending.d.ts +2 -0
  118. package/dist/operators/then-by.d.ts +2 -0
  119. package/dist/operators/to-array.d.ts +2 -0
  120. package/dist/operators/to-dictionary.d.ts +2 -0
  121. package/dist/operators/to-joined-string.d.ts +2 -0
  122. package/dist/operators/to-json-string.d.ts +2 -0
  123. package/dist/operators/to-lookup.d.ts +2 -0
  124. package/dist/operators/to-map.d.ts +2 -0
  125. package/dist/operators/to-object.d.ts +2 -0
  126. package/dist/operators/to-set.d.ts +2 -0
  127. package/dist/operators/trace.d.ts +2 -0
  128. package/dist/operators/traverse-breadth-first.d.ts +2 -0
  129. package/dist/operators/traverse-depth-first.d.ts +2 -0
  130. package/dist/operators/union-by.d.ts +2 -0
  131. package/dist/operators/union.d.ts +2 -0
  132. package/dist/operators/weighted-sample.d.ts +2 -0
  133. package/dist/operators/where-if.d.ts +2 -0
  134. package/dist/operators/where.d.ts +2 -0
  135. package/dist/operators/with-neighbors.d.ts +2 -0
  136. package/dist/operators/zip.d.ts +2 -0
  137. package/dist/src-D_Mk3oMP.js +1597 -0
  138. package/dist/types.d.ts +1154 -0
  139. package/dist/utils.d.ts +56 -0
  140. package/package.json +18 -11
  141. package/dist/linq.d.ts +0 -256
  142. package/dist/linq.js +0 -3085
  143. package/dist/linqx.d.ts +0 -36
  144. package/dist/linqx.js +0 -153
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function chunk<T>(this: IEnumerable<T>, size: number): IEnumerable<T[]>;
@@ -0,0 +1,2 @@
1
+ import type { EnumerableInput, IEnumerable } from '../types.js';
2
+ export declare function concat<T>(this: IEnumerable<T>, ...sequences: EnumerableInput<T>[]): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function contains<T, TCompare>(this: IEnumerable<T>, value: T, compareSelector?: (element: T) => TCompare): boolean;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable, KeyValuePair } from '../types.js';
2
+ export declare function countBy<T, TKey>(this: IEnumerable<T>, keySelector: (element: T) => TKey, compareSelector?: (key: TKey) => unknown): IEnumerable<KeyValuePair<TKey, number>>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function count<T>(this: IEnumerable<T>, predicate?: (element: T, index: number) => boolean): number;
@@ -0,0 +1,2 @@
1
+ import type { Comparer, IOrderedEnumerable } from '../types.js';
2
+ export declare function createOrderedEnumerable<T, TKey>(this: IOrderedEnumerable<T>, keySelector: (element: T) => TKey, comparer?: Comparer<TKey>, descending?: boolean): IOrderedEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function defaultIfEmpty<T>(this: IEnumerable<T>, defaultValue?: T): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function distinctBy<T, TKey, TCompare = TKey>(this: IEnumerable<T>, keySelector: (element: T) => TKey, compareSelector?: (key: TKey) => TCompare): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function distinctUntilChanged<T, TCompare>(this: IEnumerable<T>, compareSelector?: (element: T) => TCompare): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function distinct<T, TCompare>(this: IEnumerable<T>, compareSelector?: (element: T) => TCompare): IEnumerable<T>;
@@ -0,0 +1,3 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function doAction<T>(this: IEnumerable<T>, action: (element: T, index: number) => void): IEnumerable<T>;
3
+ export declare function doAction<T>(this: IEnumerable<T>, action: (element: T, index: number) => boolean): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function elementAtOrDefault<T>(this: IEnumerable<T>, index: number, defaultValue?: T): T | undefined;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function elementAt<T>(this: IEnumerable<T>, index: number): T;
@@ -0,0 +1,2 @@
1
+ import type { EnumerableInput, IEnumerable } from '../types.js';
2
+ export declare function exceptBy<T, TKey, TCompare = TKey>(this: IEnumerable<T>, second: EnumerableInput<TKey>, keySelector: (element: T) => TKey, compareSelector?: (key: TKey) => TCompare): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { EnumerableInput, IEnumerable } from '../types.js';
2
+ export declare function except<T, TCompare>(this: IEnumerable<T>, second: EnumerableInput<T>, compareSelector?: (element: T) => TCompare): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function finallyAction<T>(this: IEnumerable<T>, action: () => void): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function firstOrDefault<T, TDefault>(this: IEnumerable<T>, predicateOrDefault?: ((element: T, index: number) => boolean) | TDefault, defaultValue?: TDefault): T | TDefault | undefined;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function first<T>(this: IEnumerable<T>, predicate?: (element: T, index: number) => boolean): T;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function flatten<T>(this: IEnumerable<T>): IEnumerable<unknown>;
@@ -0,0 +1,3 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function forEach<T>(this: IEnumerable<T>, action: (element: T, index: number) => void): void;
3
+ export declare function forEach<T>(this: IEnumerable<T>, action: (element: T, index: number) => boolean): void;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function force<T>(this: IEnumerable<T>): void;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable, IGrouping } from '../types.js';
2
+ export declare function groupBy<T, TKey, TElement = T, TResult = IGrouping<TKey, TElement>>(this: IEnumerable<T>, keySelector: (element: T) => TKey, elementSelector?: (element: T) => TElement, resultSelector?: ((key: TKey, elements: IEnumerable<TElement>) => TResult) | undefined, compareSelector?: (key: TKey) => unknown): IEnumerable<TResult>;
@@ -0,0 +1,2 @@
1
+ import type { EnumerableInput, IEnumerable } from '../types.js';
2
+ export declare function groupJoin<TOuter, TInner, TKey, TResult>(this: IEnumerable<TOuter>, inner: EnumerableInput<TInner>, outerKeySelector: (outer: TOuter) => TKey, innerKeySelector: (inner: TInner) => TKey, resultSelector: (outer: TOuter, inner: IEnumerable<TInner>) => TResult, compareSelector?: (key: TKey) => unknown): IEnumerable<TResult>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function indexOf<T>(this: IEnumerable<T>, itemOrPredicate: T | ((element: T, index: number) => boolean)): number;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable, Indexed } from '../types.js';
2
+ export declare function index<T>(this: IEnumerable<T>): IEnumerable<Indexed<T>>;
@@ -0,0 +1,2 @@
1
+ import type { EnumerableInput, IEnumerable } from '../types.js';
2
+ export declare function insert<T>(this: IEnumerable<T>, index: number, second: EnumerableInput<T>): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { EnumerableInput, IEnumerable } from '../types.js';
2
+ export declare function intersectBy<T, TKey, TCompare = TKey>(this: IEnumerable<T>, second: EnumerableInput<TKey>, keySelector: (element: T) => TKey, compareSelector?: (key: TKey) => TCompare): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { EnumerableInput, IEnumerable } from '../types.js';
2
+ export declare function intersect<T, TCompare>(this: IEnumerable<T>, second: EnumerableInput<T>, compareSelector?: (element: T) => TCompare): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function isEmpty<T>(this: IEnumerable<T>): boolean;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function joinWith<T>(this: IEnumerable<T>, separator: string | ((element: T) => T)): string | IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { EnumerableInput, IEnumerable } from '../types.js';
2
+ export declare function join<TOuter, TInner, TKey, TResult>(this: IEnumerable<TOuter>, inner: EnumerableInput<TInner>, outerKeySelector: (outer: TOuter) => TKey, innerKeySelector: (inner: TInner) => TKey, resultSelector: (outer: TOuter, inner: TInner) => TResult, compareSelector?: (key: TKey) => unknown): IEnumerable<TResult>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function lastIndexOf<T>(this: IEnumerable<T>, itemOrPredicate: T | ((element: T, index: number) => boolean)): number;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function lastOrDefault<T, TDefault>(this: IEnumerable<T>, predicateOrDefault?: ((element: T, index: number) => boolean) | TDefault, defaultValue?: TDefault): T | TDefault | undefined;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function last<T>(this: IEnumerable<T>, predicate?: (element: T, index: number) => boolean): T;
@@ -0,0 +1,2 @@
1
+ import type { EnumerableInput, IEnumerable } from '../types.js';
2
+ export declare function leftJoin<TOuter, TInner, TKey, TResult>(this: IEnumerable<TOuter>, inner: EnumerableInput<TInner>, outerKeySelector: (outer: TOuter) => TKey, innerKeySelector: (inner: TInner) => TKey, resultSelector: (outer: TOuter, inner: TInner | null) => TResult, compareSelector?: (key: TKey) => unknown): IEnumerable<TResult>;
@@ -0,0 +1,2 @@
1
+ import type { EnumerableInput, IEnumerable } from '../types.js';
2
+ export declare function letBind<T, TResult>(this: IEnumerable<T>, func: (source: IEnumerable<T>) => EnumerableInput<TResult>): IEnumerable<TResult>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function log<T, TValue = T>(this: IEnumerable<T>, selector?: (element: T) => TValue): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function map<T, TResult>(this: IEnumerable<T>, selector: (element: T, index: number) => TResult): TResult[];
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function maxBy<T, TKey>(this: IEnumerable<T>, keySelector: (element: T) => TKey): T;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function max<T>(this: IEnumerable<T>, selector?: (element: T) => number): number;
@@ -0,0 +1,2 @@
1
+ import type { IDisposableEnumerable, IEnumerable } from '../types.js';
2
+ export declare function memoize<T>(this: IEnumerable<T>): IDisposableEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { EnumerableInput, IEnumerable } from '../types.js';
2
+ export declare function merge<T>(this: IEnumerable<T>, ...others: EnumerableInput<T>[]): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function minBy<T, TKey>(this: IEnumerable<T>, keySelector: (element: T) => TKey): T;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function min<T>(this: IEnumerable<T>, selector?: (element: T) => number): number;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function ofType<T, TResult>(this: IEnumerable<T>, type: unknown): IEnumerable<TResult>;
@@ -0,0 +1,208 @@
1
+ import { aggregate } from './aggregate.js';
2
+ import { aggregateBy } from './aggregate-by.js';
3
+ import { all } from './all.js';
4
+ import { alternate } from './alternate.js';
5
+ import { any } from './any.js';
6
+ import { append } from './append.js';
7
+ import { asEnumerable } from './as-enumerable.js';
8
+ import { average } from './average.js';
9
+ import { buffer } from './buffer.js';
10
+ import { cast } from './cast.js';
11
+ import { catchError } from './catch-error.js';
12
+ import { choose } from './choose.js';
13
+ import { chunk } from './chunk.js';
14
+ import { concat } from './concat.js';
15
+ import { contains } from './contains.js';
16
+ import { count } from './count.js';
17
+ import { countBy } from './count-by.js';
18
+ import { createOrderedEnumerable } from './create-ordered-enumerable.js';
19
+ import { defaultIfEmpty } from './default-if-empty.js';
20
+ import { distinct } from './distinct.js';
21
+ import { distinctBy } from './distinct-by.js';
22
+ import { distinctUntilChanged } from './distinct-until-changed.js';
23
+ import { doAction } from './do-action.js';
24
+ import { elementAt } from './element-at.js';
25
+ import { elementAtOrDefault } from './element-at-or-default.js';
26
+ import { except } from './except.js';
27
+ import { exceptBy } from './except-by.js';
28
+ import { finallyAction } from './finally-action.js';
29
+ import { first } from './first.js';
30
+ import { firstOrDefault } from './first-or-default.js';
31
+ import { flatten } from './flatten.js';
32
+ import { force } from './force.js';
33
+ import { forEach } from './for-each.js';
34
+ import { groupBy } from './group-by.js';
35
+ import { groupJoin } from './group-join.js';
36
+ import { index } from './index.js';
37
+ import { indexOf } from './index-of.js';
38
+ import { insert } from './insert.js';
39
+ import { intersect } from './intersect.js';
40
+ import { intersectBy } from './intersect-by.js';
41
+ import { isEmpty } from './is-empty.js';
42
+ import { join } from './join.js';
43
+ import { joinWith } from './join-with.js';
44
+ import { last } from './last.js';
45
+ import { lastIndexOf } from './last-index-of.js';
46
+ import { lastOrDefault } from './last-or-default.js';
47
+ import { leftJoin } from './left-join.js';
48
+ import { letBind } from './let-bind.js';
49
+ import { log } from './log.js';
50
+ import { map } from './map.js';
51
+ import { max } from './max.js';
52
+ import { maxBy } from './max-by.js';
53
+ import { memoize } from './memoize.js';
54
+ import { merge } from './merge.js';
55
+ import { min } from './min.js';
56
+ import { minBy } from './min-by.js';
57
+ import { ofType } from './of-type.js';
58
+ import { orderBy } from './order-by.js';
59
+ import { orderByDescending } from './order-by-descending.js';
60
+ import { page } from './page.js';
61
+ import { pairwise } from './pairwise.js';
62
+ import { partitionBy } from './partition-by.js';
63
+ import { position } from './position.js';
64
+ import { prepend } from './prepend.js';
65
+ import { reverse } from './reverse.js';
66
+ import { rightJoin } from './right-join.js';
67
+ import { scan } from './scan.js';
68
+ import { select } from './select.js';
69
+ import { selectMany } from './select-many.js';
70
+ import { sequenceEqual } from './sequence-equal.js';
71
+ import { share } from './share.js';
72
+ import { shuffle } from './shuffle.js';
73
+ import { single } from './single.js';
74
+ import { singleOrDefault } from './single-or-default.js';
75
+ import { skip } from './skip.js';
76
+ import { skipLast } from './skip-last.js';
77
+ import { skipWhile } from './skip-while.js';
78
+ import { sum } from './sum.js';
79
+ import { take } from './take.js';
80
+ import { takeExceptLast } from './take-except-last.js';
81
+ import { takeFromLast } from './take-from-last.js';
82
+ import { takeLast } from './take-last.js';
83
+ import { takeWhile } from './take-while.js';
84
+ import { thenBy } from './then-by.js';
85
+ import { thenByDescending } from './then-by-descending.js';
86
+ import { toArray } from './to-array.js';
87
+ import { toDictionary } from './to-dictionary.js';
88
+ import { toJoinedString } from './to-joined-string.js';
89
+ import { toJSONString } from './to-json-string.js';
90
+ import { toLookup } from './to-lookup.js';
91
+ import { toMap } from './to-map.js';
92
+ import { toObject } from './to-object.js';
93
+ import { toSet } from './to-set.js';
94
+ import { trace } from './trace.js';
95
+ import { traverseBreadthFirst } from './traverse-breadth-first.js';
96
+ import { traverseDepthFirst } from './traverse-depth-first.js';
97
+ import { union } from './union.js';
98
+ import { unionBy } from './union-by.js';
99
+ import { weightedSample } from './weighted-sample.js';
100
+ import { where } from './where.js';
101
+ import { whereIf } from './where-if.js';
102
+ import { withNeighbors } from './with-neighbors.js';
103
+ import { zip } from './zip.js';
104
+ export declare const instanceOperators: {
105
+ aggregate: typeof aggregate;
106
+ aggregateBy: typeof aggregateBy;
107
+ all: typeof all;
108
+ alternate: typeof alternate;
109
+ any: typeof any;
110
+ append: typeof append;
111
+ asEnumerable: typeof asEnumerable;
112
+ average: typeof average;
113
+ buffer: typeof buffer;
114
+ cast: typeof cast;
115
+ catchError: typeof catchError;
116
+ choose: typeof choose;
117
+ chunk: typeof chunk;
118
+ concat: typeof concat;
119
+ contains: typeof contains;
120
+ count: typeof count;
121
+ countBy: typeof countBy;
122
+ createOrderedEnumerable: typeof createOrderedEnumerable;
123
+ defaultIfEmpty: typeof defaultIfEmpty;
124
+ distinct: typeof distinct;
125
+ distinctBy: typeof distinctBy;
126
+ distinctUntilChanged: typeof distinctUntilChanged;
127
+ doAction: typeof doAction;
128
+ elementAt: typeof elementAt;
129
+ elementAtOrDefault: typeof elementAtOrDefault;
130
+ except: typeof except;
131
+ exceptBy: typeof exceptBy;
132
+ finallyAction: typeof finallyAction;
133
+ first: typeof first;
134
+ firstOrDefault: typeof firstOrDefault;
135
+ flatten: typeof flatten;
136
+ force: typeof force;
137
+ forEach: typeof forEach;
138
+ groupBy: typeof groupBy;
139
+ groupJoin: typeof groupJoin;
140
+ index: typeof index;
141
+ indexOf: typeof indexOf;
142
+ insert: typeof insert;
143
+ intersect: typeof intersect;
144
+ intersectBy: typeof intersectBy;
145
+ isEmpty: typeof isEmpty;
146
+ join: typeof join;
147
+ joinWith: typeof joinWith;
148
+ last: typeof last;
149
+ lastIndexOf: typeof lastIndexOf;
150
+ lastOrDefault: typeof lastOrDefault;
151
+ leftJoin: typeof leftJoin;
152
+ letBind: typeof letBind;
153
+ log: typeof log;
154
+ map: typeof map;
155
+ max: typeof max;
156
+ maxBy: typeof maxBy;
157
+ memoize: typeof memoize;
158
+ merge: typeof merge;
159
+ min: typeof min;
160
+ minBy: typeof minBy;
161
+ ofType: typeof ofType;
162
+ orderBy: typeof orderBy;
163
+ orderByDescending: typeof orderByDescending;
164
+ page: typeof page;
165
+ pairwise: typeof pairwise;
166
+ partitionBy: typeof partitionBy;
167
+ position: typeof position;
168
+ prepend: typeof prepend;
169
+ reverse: typeof reverse;
170
+ rightJoin: typeof rightJoin;
171
+ scan: typeof scan;
172
+ select: typeof select;
173
+ selectMany: typeof selectMany;
174
+ sequenceEqual: typeof sequenceEqual;
175
+ share: typeof share;
176
+ shuffle: typeof shuffle;
177
+ single: typeof single;
178
+ singleOrDefault: typeof singleOrDefault;
179
+ skip: typeof skip;
180
+ skipLast: typeof skipLast;
181
+ skipWhile: typeof skipWhile;
182
+ sum: typeof sum;
183
+ take: typeof take;
184
+ takeExceptLast: typeof takeExceptLast;
185
+ takeFromLast: typeof takeFromLast;
186
+ takeLast: typeof takeLast;
187
+ takeWhile: typeof takeWhile;
188
+ thenBy: typeof thenBy;
189
+ thenByDescending: typeof thenByDescending;
190
+ toArray: typeof toArray;
191
+ toDictionary: typeof toDictionary;
192
+ toJoinedString: typeof toJoinedString;
193
+ toJSONString: typeof toJSONString;
194
+ toLookup: typeof toLookup;
195
+ toMap: typeof toMap;
196
+ toObject: typeof toObject;
197
+ toSet: typeof toSet;
198
+ trace: typeof trace;
199
+ traverseBreadthFirst: typeof traverseBreadthFirst;
200
+ traverseDepthFirst: typeof traverseDepthFirst;
201
+ union: typeof union;
202
+ unionBy: typeof unionBy;
203
+ weightedSample: typeof weightedSample;
204
+ where: typeof where;
205
+ whereIf: typeof whereIf;
206
+ withNeighbors: typeof withNeighbors;
207
+ zip: typeof zip;
208
+ };
@@ -0,0 +1,2 @@
1
+ import type { Comparer, IEnumerable, IOrderedEnumerable } from '../types.js';
2
+ export declare function orderByDescending<T, TKey>(this: IEnumerable<T>, keySelector: (element: T) => TKey, comparer?: Comparer<TKey>): IOrderedEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { Comparer, IEnumerable, IOrderedEnumerable } from '../types.js';
2
+ export declare function orderBy<T, TKey>(this: IEnumerable<T>, keySelector: (element: T) => TKey, comparer?: Comparer<TKey>): IOrderedEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable, IPageInfo } from '../types.js';
2
+ export declare function page<T>(this: IEnumerable<T>, pageNumberOrInfo: number | IPageInfo, pageSize?: number): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function pairwise<T, TResult>(this: IEnumerable<T>, selector: (prev: T, current: T) => TResult): IEnumerable<TResult>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable, IGrouping } from '../types.js';
2
+ export declare function partitionBy<T, TKey, TElement = T, TResult = IGrouping<TKey, TElement>>(this: IEnumerable<T>, keySelector: (element: T) => TKey, elementSelector?: (element: T) => TElement, resultSelector?: ((key: TKey, elements: IEnumerable<TElement>) => TResult) | undefined, compareSelector?: (key: TKey) => unknown): IEnumerable<TResult>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable, Positioned } from '../types.js';
2
+ export declare function position<T>(this: IEnumerable<T>): IEnumerable<Positioned<T>>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function prepend<T>(this: IEnumerable<T>, element: T): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function reverse<T>(this: IEnumerable<T>): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { EnumerableInput, IEnumerable } from '../types.js';
2
+ export declare function rightJoin<TOuter, TInner, TKey, TResult>(this: IEnumerable<TOuter>, inner: EnumerableInput<TInner>, outerKeySelector: (outer: TOuter) => TKey, innerKeySelector: (inner: TInner) => TKey, resultSelector: (outer: TOuter | null, inner: TInner) => TResult, compareSelector?: (key: TKey) => unknown): IEnumerable<TResult>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function scan<T, TAccumulate>(this: IEnumerable<T>, seedOrFunc: TAccumulate | ((prev: T, current: T) => T), optionalFunc?: (prev: TAccumulate, current: T) => TAccumulate): IEnumerable<T | TAccumulate>;
@@ -0,0 +1,2 @@
1
+ import type { EnumerableInput, IEnumerable } from '../types.js';
2
+ export declare function selectMany<T, TCollection, TResult = TCollection>(this: IEnumerable<T>, collectionSelector: (element: T, index: number) => EnumerableInput<TCollection>, resultSelector?: (outer: T, inner: TCollection) => TResult): IEnumerable<TCollection | TResult>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function select<T, TResult>(this: IEnumerable<T>, selector: (element: T, index: number) => TResult): IEnumerable<TResult>;
@@ -0,0 +1,2 @@
1
+ import type { EnumerableInput, IEnumerable } from '../types.js';
2
+ export declare function sequenceEqual<T, TCompare>(this: IEnumerable<T>, second: EnumerableInput<T>, compareSelector?: (element: T) => TCompare): boolean;
@@ -0,0 +1,2 @@
1
+ import type { IDisposableEnumerable, IEnumerable } from '../types.js';
2
+ export declare function share<T>(this: IEnumerable<T>): IDisposableEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function shuffle<T>(this: IEnumerable<T>): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function singleOrDefault<T, TDefault>(this: IEnumerable<T>, predicateOrDefault?: ((element: T, index: number) => boolean) | TDefault, defaultValue?: TDefault): T | TDefault | undefined;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function single<T>(this: IEnumerable<T>, predicate?: (element: T, index: number) => boolean): T;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function skipLast<T>(this: IEnumerable<T>, count: number): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function skipWhile<T>(this: IEnumerable<T>, predicate: (element: T, index: number) => boolean): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function skip<T>(this: IEnumerable<T>, count: number): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function sum<T>(this: IEnumerable<T>, selector?: (element: T) => number): number;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function takeExceptLast<T>(this: IEnumerable<T>, count?: number): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function takeFromLast<T>(this: IEnumerable<T>, count: number): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function takeLast<T>(this: IEnumerable<T>, count: number): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function takeWhile<T>(this: IEnumerable<T>, predicate: (element: T, index: number) => boolean): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function take<T>(this: IEnumerable<T>, count: number): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { Comparer, IOrderedEnumerable } from '../types.js';
2
+ export declare function thenByDescending<T, TKey>(this: IOrderedEnumerable<T>, keySelector: (element: T) => TKey, comparer?: Comparer<TKey>): IOrderedEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { Comparer, IOrderedEnumerable } from '../types.js';
2
+ export declare function thenBy<T, TKey>(this: IOrderedEnumerable<T>, keySelector: (element: T) => TKey, comparer?: Comparer<TKey>): IOrderedEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function toArray<T>(this: IEnumerable<T>): T[];
@@ -0,0 +1,2 @@
1
+ import type { IDictionary, IEnumerable } from '../types.js';
2
+ export declare function toDictionary<T, TKey, TValue = T>(this: IEnumerable<T>, keySelector: (element: T) => TKey, elementSelector?: (element: T) => TValue, compareSelector?: (key: TKey) => unknown): IDictionary<TKey, TValue>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function toJoinedString<T, TResult = T>(this: IEnumerable<T>, separator?: string, selector?: (element: T, index: number) => TResult): string;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function toJSONString<T>(this: IEnumerable<T>, replacer?: ((key: string, value: unknown) => unknown) | (string | number)[], space?: string | number): string;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable, ILookup } from '../types.js';
2
+ export declare function toLookup<T, TKey, TElement = T>(this: IEnumerable<T>, keySelector: (element: T) => TKey, elementSelector?: (element: T) => TElement, compareSelector?: (key: TKey) => unknown): ILookup<TKey, TElement>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function toMap<T, TKey, TValue>(this: IEnumerable<T>, keySelector: (element: T) => TKey, valueSelector: (element: T) => TValue): Map<TKey, TValue>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function toObject<T, TKey extends PropertyKey, TElement = T>(this: IEnumerable<T>, keySelector: (element: T) => TKey, elementSelector?: (element: T) => TElement): Record<TKey, TElement>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function toSet<T>(this: IEnumerable<T>): Set<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function trace<T, TValue = T>(this: IEnumerable<T>, message?: string, selector?: (element: T) => TValue): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function traverseBreadthFirst<T, TResult = T>(this: IEnumerable<T>, childrenSelector: (element: T) => IEnumerable<T>, resultSelector?: (element: T, nestLevel: number) => TResult): IEnumerable<TResult>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function traverseDepthFirst<T, TResult = T>(this: IEnumerable<T>, childrenSelector: (element: T) => IEnumerable<T>, resultSelector?: (element: T, nestLevel: number) => TResult): IEnumerable<TResult>;
@@ -0,0 +1,2 @@
1
+ import type { EnumerableInput, IEnumerable } from '../types.js';
2
+ export declare function unionBy<T, TKey, TCompare = TKey>(this: IEnumerable<T>, second: EnumerableInput<T>, keySelector: (element: T) => TKey, compareSelector?: (key: TKey) => TCompare): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { EnumerableInput, IEnumerable } from '../types.js';
2
+ export declare function union<T, TCompare>(this: IEnumerable<T>, second: EnumerableInput<T>, compareSelector?: (element: T) => TCompare): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function weightedSample<T>(this: IEnumerable<T>, weightSelector: (element: T) => number): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function whereIf<T>(this: IEnumerable<T>, flag: boolean | string | undefined | null, filter: (element: T) => boolean): IEnumerable<T>;
@@ -0,0 +1,2 @@
1
+ import type { IEnumerable } from '../types.js';
2
+ export declare function where<T>(this: IEnumerable<T>, predicate: (element: T, index: number) => boolean): IEnumerable<T>;