import { nothing, TemplateResult } from 'lit';
import { IRequestLog, RequestLog as CoreRequestLog, Headers, RequestTime, ResponseRedirect, AssertionResult, AssertionError } from "@api-client/core/build/browser.js";
import ApiElement from '../ApiElement.js';
import { TabSelectionDetail } from '../../ui/tabs/UiTabs.js';
import '../../define/http/http-log-headers.js';
import '../../define/http/http-log-body.js';
import '../../define/http/http-log-timings.js';
import '../../define/ui/ui-tab.js';
import '../../define/ui/ui-tabs.js';
import '../../define/ui/ui-divider.js';
export declare enum RequestLogView {
    headers = "headers",
    payload = "payload",
    preview = "preview",
    response = "response",
    timings = "timings",
    redirects = "redirects",
    assertions = "assertions"
}
/**
 * An element that renders the view for a core's `IRequestLog`.
 */
export default class RequestLog extends ApiElement {
    protected httpLogInternal?: IRequestLog | CoreRequestLog;
    /**
     * This property is set when the `httpLog` is set.
     * It always represent an instance of the `RequestLog` (or undefined) regardless of the input format.
     */
    protected effectiveLog?: CoreRequestLog;
    /**
     * The request log to render. When not set it renders nothing.
     */
    get httpLog(): IRequestLog | CoreRequestLog | undefined;
    set httpLog(value: IRequestLog | CoreRequestLog | undefined);
    /**
     * Currently rendered view.
     * @attribute
     */
    view: RequestLogView;
    /**
     * Returns `true` when the request has a payload message.
     */
    get hasRequestPayload(): boolean;
    /**
     * Returns `true` when the response has a payload message.
     */
    get hasResponsePayload(): boolean;
    get hasResponse(): boolean;
    protected isErrorResponse: boolean;
    protected timingsData?: RequestTime[];
    protected redirectsData?: ResponseRedirect[];
    /**
     * Reads the payload to the original format for both the request and the response.
     */
    protected processPayload(): Promise<void>;
    protected handleViewSelect(e: CustomEvent<TabSelectionDetail>): void;
    protected render(): TemplateResult;
    protected renderTabs(effectiveLog?: CoreRequestLog): TemplateResult;
    protected renderAssertionsBadge(effectiveLog?: CoreRequestLog): TemplateResult | typeof nothing;
    protected renderContent(effectiveLog?: CoreRequestLog): TemplateResult;
    /**
     * Renders basic information about the request:
     * - request method & URL
     * - request headers
     * - response headers
     */
    protected renderHeaders(info: CoreRequestLog): TemplateResult;
    /**
     * @returns The template for the "raw" response body view.
     */
    protected renderPayload(info: CoreRequestLog): TemplateResult;
    /**
     * @returns The template for the parsed response body view.
     */
    protected renderPreview(info: CoreRequestLog): TemplateResult;
    protected renderResponse(info: CoreRequestLog): TemplateResult;
    protected renderTimings(): TemplateResult;
    protected renderRedirects(): TemplateResult;
    protected renderRedirect(item: ResponseRedirect, index: number): TemplateResult;
    protected renderHeadersRaw(header: Headers): TemplateResult | string;
    protected _noDataTemplate(arialLabelledBy: string, id: string): TemplateResult;
    protected renderAssertions(info: CoreRequestLog): TemplateResult;
    renderAssertion(item: AssertionResult): TemplateResult;
    renderOkAssertion(description: string): TemplateResult;
    renderFailedAssertion(description: string, error: AssertionError): TemplateResult;
}
//# sourceMappingURL=RequestLog.d.ts.map