@odata2ts/odata-query-objects
Version:
Q-Objects are the magic sauce for the odata-query-builder and allow for renaming and type conversion
19 lines (18 loc) • 1.15 kB
TypeScript
import { StringFilterFunctions } from "../../odata/ODataModel";
import { formatWithQuotes } from "../../param/UrlParamHelper";
import { QFilterExpression } from "../../QFilterExpression";
import { InputModel, QBasePath } from "./QBasePath";
export declare abstract class QStringBasePath<SubClass extends QStringBasePath<any, any>, ConvertedType> extends QBasePath<string, ConvertedType> {
protected abstract create(path: string): SubClass;
protected formatValue: typeof formatWithQuotes;
protected getFunctionExpression(func: StringFilterFunctions, value: InputModel<this["converter"]>): string;
protected buildFunctionFilter(func: StringFilterFunctions, value: InputModel<this["converter"]>): QFilterExpression;
protected buildNoValueFunc(func: StringFilterFunctions): SubClass;
concatPrefix(value: InputModel<this["converter"]>): SubClass;
concatSuffix(value: InputModel<this["converter"]>): SubClass;
startsWith(value: InputModel<this["converter"]>): QFilterExpression;
endsWith(value: InputModel<this["converter"]>): QFilterExpression;
toLower(): SubClass;
toUpper(): SubClass;
trim(): SubClass;
}