Remove unused models

Signed-off-by: trivernis <trivernis@protonmail.com>
pull/14/head
trivernis 3 years ago
parent 6e150a3701
commit 3f37fb4e5e
Signed by: Trivernis
GPG Key ID: DFFFCC2C7A02DB45

@ -1,16 +0,0 @@
export class TagQuery {
constructor(public tag: string, public negate: boolean) {
}
public static fromString(tag: string): TagQuery {
if (tag.startsWith("-")) {
return new TagQuery(tag.replace(/^-/g, ""), true);
} else {
return new TagQuery(tag, false);
}
}
public getNormalizedTag(): string {
return this.negate ? "-" + this.tag : this.tag;
}
}

@ -1,10 +0,0 @@
export type RustEnum<VariantData> = {
[key: string]: VariantData
};
export function createRustEnum<T, VariantData>(variant: string, data: VariantData): T {
let enumInstance: RustEnum<VariantData> = {};
enumInstance[variant] = data;
return enumInstance as unknown as T;
}
Loading…
Cancel
Save