import * as bunyan from "bunyan";
import * as knex from "knex";
import * as knexPostgis from "knex-postgis";
import * as Joi from "joi";
import * as ts from "./interfaces";
export declare const genericResourceCall: (operation: string, schema: Joi.Schema, fields: string[], toQuery: any, caller: ts.IClassResource) => (input: ts.IParamsProcessBase | ts.IParamsProcessWithSearch | ts.IParamsProcessDelete) => Promise<ts.IRejectResource | ts.IResolveResource>;
export declare class Resource implements ts.IClassResource {
    db: knex;
    st: knexPostgis.KnexPostgis;
    logger: bunyan;
    name: string;
    validator: Joi.Schema;
    schemaResource: ts.ISchemaResource;
    middlewareFn: ts.IObjectTransformer;
    hasSubquery: boolean;
    subResourceName?: string;
    aggregationFn?: ts.TKnexSubQuery;
    geoFields?: ts.IObjectGeoFields;
    supportsReturn: boolean;
    pageLimit: number;
    schema: ts.IValidationExpanderSchema;
    report: ts.IValidationExpanderReport;
    meta: ts.IValidationExpanderMeta;
    generics: ts.TResponseGenerics;
    constructor({ db, st, logger, name, validator, schemaResource, middlewareFn, subResourceName, aggregationFn, geoFields, supportsReturn, pageLimit, redactedFields, }: ts.IClassResourceConstructor);
    queryBase(): {
        db: knex<any, unknown[]>;
        st: knexPostgis.KnexPostgis;
        resource: string;
        schemaResource: ts.ISchemaResource;
    };
    contextParser(input: ts.IParamsProcessBase): {
        context: ts.ISearchQueryContext;
        errorType: string;
        error: Error;
        result?: undefined;
    };
    create(input: ts.IParamsProcessBase): ts.TAsyncResourceResponse;
    read(input: ts.IParamsProcessBase): ts.TAsyncResourceResponse;
    update(input: ts.IParamsProcessWithSearch): ts.TAsyncResourceResponse;
    delete(input: ts.IParamsProcessDelete): ts.TAsyncResourceResponse;
    search(input: ts.IParamsProcessBase, { subqueryContext, ...subqueryOptions }?: ts.ISubqueryOptions): Promise<ts.IRejectResource | ts.IResolveResource>;
    transformRecords(records: any[]): any[];
}
