swc/crates/swc_bundler/tests/.cache/deno/85e4e2aa98d009b187a72395227719f9f1253b56.ts
2021-11-09 20:42:49 +09:00

21 lines
654 B
TypeScript

// Loaded from https://deno.land/x/denodb@v1.0.18/lib/translators/translator.ts
import type { Query, QueryDescription } from "../query-builder.ts";
import type { FieldAlias } from "../data-types.ts";
/** Translator interface for translating `QueryDescription` objects to regular queries. */
export class Translator {
/** Translate a query description into a regular query. */
translateToQuery(query: QueryDescription): Query {
return "";
}
/** Format a field to the database format, e.g. `userName` to `user_name`. */
formatFieldNameToDatabase(
fieldName: string | FieldAlias,
): string | FieldAlias {
return fieldName;
}
}