import * as i0 from '@angular/core';
import { Injector } from '@angular/core';
import { AXPEntity, AXPMenuProvider, AXPMenuProviderContext, AXPSearchCommandProvider, AXPSearchResult, AXPSettingDefinitionProvider, AXPSettingDefinitionProviderContext } from '@acorex/platform/common';
import { AXPEntityModel, AXMEntityCrudServiceImpl, AXPEntityDefinitionLoader, AXPEntityDefinitionPreloader, AXPEntityPreloadEntity } from '@acorex/platform/layout/entity';

declare class AXMAxpLogEntityModule {
    static ɵfac: i0.ɵɵFactoryDeclaration<AXMAxpLogEntityModule, never>;
    static ɵmod: i0.ɵɵNgModuleDeclaration<AXMAxpLogEntityModule, never, never, never>;
    static ɵinj: i0.ɵɵInjectorDeclaration<AXMAxpLogEntityModule>;
}

declare class AXMLogManagementModule {
    static ɵfac: i0.ɵɵFactoryDeclaration<AXMLogManagementModule, never>;
    static ɵmod: i0.ɵɵNgModuleDeclaration<AXMLogManagementModule, never, [typeof AXMAxpLogEntityModule], never>;
    static ɵinj: i0.ɵɵInjectorDeclaration<AXMLogManagementModule>;
}

declare const RootConfig: {
    config: {
        i18n: string;
    };
    module: {
        route: string;
        module: string;
        name: string;
        title: string;
        icon: string;
    };
    entities: {
        axpLog: {
            name: string;
            title: string;
            titlePlural: string;
            icon: string;
        };
    };
};

declare function axpLogFactory(injector: Injector): Promise<AXPEntity | null>;

interface AXMLogManagementAxpLogEntityModel extends AXPEntityModel<string> {
    applicationName: string;
    tenantId?: string;
    tenantName?: string;
    userId?: string;
    userName?: string;
    executionTime: Date;
    executionDuration: number;
    clientIpAddress?: string;
    clientName?: string;
    clientId?: string;
    correlationId?: string;
    browserInfo?: string;
    httpMethod?: string;
    url?: string;
    httpStatusCode?: number;
    httpStatus?: string;
    exceptions?: string;
    comments?: string;
    impersonatorUserId?: string;
    impersonatorUserName?: string;
    impersonatorTenantId?: string;
    impersonatorTenantName?: string;
    extraProperties?: Record<string, any>;
    actions?: AuditLogActionDto[];
    entityChanges?: EntityChangeDto[];
}
interface AuditLogActionDto {
    serviceName?: string;
    methodName?: string;
    parameters?: string;
    executionTime: Date;
    executionDuration: number;
    extraProperties?: Record<string, any>;
}
interface EntityChangeDto {
    changeTime: Date;
    entityId: string;
    entityTypeFullName: string;
    changeType: string;
    propertyChanges?: EntityPropertyChangeDto[];
    extraProperties?: Record<string, any>;
}
interface EntityPropertyChangeDto {
    propertyName: string;
    propertyTypeFullName: string;
    originalValue?: string;
    newValue?: string;
}

declare abstract class AXMAxpLogService extends AXMEntityCrudServiceImpl<string, AXMLogManagementAxpLogEntityModel> {
}
declare class AXMAxpLogServiceImpl extends AXMAxpLogService {
    constructor();
    static ɵfac: i0.ɵɵFactoryDeclaration<AXMAxpLogServiceImpl, never>;
    static ɵprov: i0.ɵɵInjectableDeclaration<AXMAxpLogServiceImpl>;
}

declare class AXMEntityProvider implements AXPEntityDefinitionLoader, AXPEntityDefinitionPreloader {
    private injector;
    preload(): AXPEntityPreloadEntity[];
    get(moduleName: string, entityName: string): Promise<AXPEntity | null>;
    static ɵfac: i0.ɵɵFactoryDeclaration<AXMEntityProvider, never>;
    static ɵprov: i0.ɵɵInjectableDeclaration<AXMEntityProvider>;
}

declare class AXMMenuProvider implements AXPMenuProvider {
    private entityService;
    provide(context: AXPMenuProviderContext): Promise<void>;
}

declare class AXMSearchCommandProvider extends AXPSearchCommandProvider {
    commands: AXPSearchResult[];
}

/**
 * Settings provider for the Log Management module.
 * Implements configuration options for log retention, storage, levels, alerts, and performance.
 */
declare class AXPLogManagementSettingProvider implements AXPSettingDefinitionProvider {
    private readonly injector;
    private readonly translateService;
    constructor(injector: Injector);
    provide(context: AXPSettingDefinitionProviderContext): Promise<void>;
}

export { AXMAxpLogService, AXMAxpLogServiceImpl, AXMEntityProvider, AXMLogManagementModule, AXMMenuProvider, AXMSearchCommandProvider, AXPLogManagementSettingProvider, RootConfig, axpLogFactory };
export type { AXMLogManagementAxpLogEntityModel, AuditLogActionDto, EntityChangeDto, EntityPropertyChangeDto };
