Update TypeScript
This commit is contained in:
1 parent
f4692faed6
commit
0861b2db40
9 files changed
+38
-38
No files matched your search
@@ -21,13 +21,13 @@ import { PermissionSet, Expression } from "../types";
|
||||
import { evaluate, or } from "./expression";
|
||||
|
||||
export default class Authorizer {
|
||||
private permissionSets: PermissionSet[];
|
||||
private validatorCache: WeakMap<
|
||||
private declare permissionSets: PermissionSet[];
|
||||
private declare validatorCache: WeakMap<
|
||||
any,
|
||||
(mutationType, mutation, any) => boolean
|
||||
>;
|
||||
private hasAccessCache: Map<string, boolean>;
|
||||
private getFilterCache: Map<string, Expression>;
|
||||
private declare hasAccessCache: Map<string, boolean>;
|
||||
private declare getFilterCache: Map<string, Expression>;
|
||||
|
||||
public constructor(permissionSets: PermissionSet[]) {
|
||||
this.permissionSets = permissionSets;
|
||||
|
||||
@@ -29,8 +29,8 @@ const TWO = BI.BigInt(2);
|
||||
const NEGATIVE_ONE = BI.BigInt(-1);
|
||||
|
||||
class Indeterminates {
|
||||
public map: Map<string, number>;
|
||||
public sortedKeys: string[];
|
||||
public declare map: Map<string, number>;
|
||||
public declare sortedKeys: string[];
|
||||
|
||||
public constructor(str?: string) {
|
||||
this.map = new Map();
|
||||
@@ -118,7 +118,7 @@ function findGcd(a: BI.bigint, b: BI.bigint): BI.bigint {
|
||||
}
|
||||
|
||||
class Polynomial {
|
||||
public terms: Term[];
|
||||
public declare terms: Term[];
|
||||
|
||||
public constructor(terms: Term[]) {
|
||||
this.terms = terms;
|
||||
@@ -343,8 +343,8 @@ class NullSynth extends BoolExprSynth {
|
||||
}
|
||||
|
||||
class VarSynth extends BoolExprSynth {
|
||||
private expStr: string;
|
||||
private negate: boolean;
|
||||
private declare expStr: string;
|
||||
private declare negate: boolean;
|
||||
public constructor(exp: Expression) {
|
||||
super();
|
||||
this.negate = false;
|
||||
@@ -388,7 +388,7 @@ class VarSynth extends BoolExprSynth {
|
||||
}
|
||||
|
||||
class NotSynth extends BoolExprSynth {
|
||||
private exprSynth: BoolExprSynth;
|
||||
private declare exprSynth: BoolExprSynth;
|
||||
public constructor(e: BoolExprSynth) {
|
||||
super();
|
||||
this.exprSynth = e;
|
||||
@@ -405,7 +405,7 @@ class NotSynth extends BoolExprSynth {
|
||||
}
|
||||
|
||||
class IsNullSynth extends BoolExprSynth {
|
||||
private exprSynth: BoolExprSynth;
|
||||
private declare exprSynth: BoolExprSynth;
|
||||
public constructor(e: BoolExprSynth) {
|
||||
super();
|
||||
this.exprSynth = e;
|
||||
@@ -422,7 +422,7 @@ class IsNullSynth extends BoolExprSynth {
|
||||
}
|
||||
|
||||
class OrSynth extends BoolExprSynth {
|
||||
private exprSynths: BoolExprSynth[];
|
||||
private declare exprSynths: BoolExprSynth[];
|
||||
public constructor(...e: BoolExprSynth[]) {
|
||||
super();
|
||||
this.exprSynths = e.filter((ee) => !(ee instanceof FalseSynth));
|
||||
@@ -465,7 +465,7 @@ class OrSynth extends BoolExprSynth {
|
||||
}
|
||||
|
||||
class AndSynth extends BoolExprSynth {
|
||||
private exprSynths: BoolExprSynth[];
|
||||
private declare exprSynths: BoolExprSynth[];
|
||||
public constructor(...e: BoolExprSynth[]) {
|
||||
super();
|
||||
this.exprSynths = e.filter((ee) => !(ee instanceof TrueSynth));
|
||||
@@ -508,7 +508,7 @@ class AndSynth extends BoolExprSynth {
|
||||
}
|
||||
|
||||
class CaseSynth extends BoolExprSynth {
|
||||
private exprSynths: BoolExprSynth[];
|
||||
private declare exprSynths: BoolExprSynth[];
|
||||
public constructor(e: BoolExprSynth[]) {
|
||||
super();
|
||||
this.exprSynths = e;
|
||||
|
||||
@@ -20,9 +20,9 @@
|
||||
import Path from "./path";
|
||||
|
||||
export default class PathSet {
|
||||
private lengthIndex: Set<Path>[];
|
||||
private fragmentIndex: Map<string, Set<Path>>[];
|
||||
private stringIndex: Map<string, Path>;
|
||||
private declare lengthIndex: Set<Path>[];
|
||||
private declare fragmentIndex: Map<string, Set<Path>>[];
|
||||
private declare stringIndex: Map<string, Path>;
|
||||
|
||||
public constructor() {
|
||||
this.lengthIndex = [];
|
||||
|
||||
+5
-5
@@ -49,11 +49,11 @@ function legalChar(c: number): boolean {
|
||||
}
|
||||
|
||||
export default class Path {
|
||||
public readonly segments: Segments;
|
||||
public readonly wildcard: number;
|
||||
public readonly alias: number;
|
||||
protected _string: string;
|
||||
protected _stringIndex: number[];
|
||||
public declare readonly segments: Segments;
|
||||
public declare readonly wildcard: number;
|
||||
public declare readonly alias: number;
|
||||
protected declare _string: string;
|
||||
protected declare _stringIndex: number[];
|
||||
|
||||
protected static parseAliasValue(
|
||||
pattern: string,
|
||||
|
||||
+1
-1
@@ -22,7 +22,7 @@ interface Instance {
|
||||
}
|
||||
|
||||
export default class InstanceSet {
|
||||
private set: Set<Instance>;
|
||||
private declare set: Set<Instance>;
|
||||
|
||||
public constructor() {
|
||||
this.set = new Set();
|
||||
|
||||
@@ -26,10 +26,10 @@ interface Revisions<V> {
|
||||
}
|
||||
|
||||
export default class VersionedMap<K, V> {
|
||||
private _sizeDiff: number[];
|
||||
private _revision: number;
|
||||
private map: Map<K, (V | symbol)[]>;
|
||||
public dirty: number;
|
||||
private declare _sizeDiff: number[];
|
||||
private declare _revision: number;
|
||||
private declare map: Map<K, (V | symbol)[]>;
|
||||
public declare dirty: number;
|
||||
|
||||
public constructor() {
|
||||
this._sizeDiff = [0];
|
||||
|
||||
Reference in new issue
Block a user