import { BaseEntity, CompositeKey, EntityInfo } from "@memberjunction/core";
import { MJListDetailEntity } from "../generated/entity_subclasses.js";
export declare class MJListDetailEntityExtended extends MJListDetailEntity {
    private _recordCompositeKey;
    private _sourceEntityInfo;
    /**
     * Sets the RecordID from a source entity record.
     * For single PK entities, stores just the raw PK value.
     * For composite PK entities, stores the concatenated key format (Field1|Value1||Field2|Value2).
     * @param entityInfo The EntityInfo for the source entity
     * @param record The source record (can be a BaseEntity or plain object with PK values)
     */
    SetRecordIDFromEntity(entityInfo: EntityInfo, record: BaseEntity | Record<string, unknown>): void;
    /**
     * Gets a CompositeKey from the stored RecordID.
     * Lazily builds and caches the CompositeKey.
     * @param entityInfo Optional EntityInfo - required if not previously set via SetRecordIDFromEntity
     * @returns CompositeKey representing the stored RecordID
     */
    GetCompositeKey(entityInfo?: EntityInfo): CompositeKey;
    /**
     * Extracts the raw primary key value(s) from the RecordID.
     * For single PK, returns the raw value directly.
     * For composite PK, returns an object with field names and values.
     * @param entityInfo The EntityInfo for the source entity
     * @returns The raw PK value (string) for single PK, or Record<string, unknown> for composite
     */
    GetRawPrimaryKeyValue(entityInfo: EntityInfo): string | Record<string, unknown>;
    /**
     * Static utility to build the appropriate RecordID value from a source record.
     * Use this when you need to build a RecordID without creating a MJListDetailEntity.
     * @param entityInfo The EntityInfo for the source entity
     * @param record The source record
     * @returns The properly formatted RecordID string
     */
    static BuildRecordID(entityInfo: EntityInfo, record: BaseEntity | Record<string, unknown>): string;
    /**
     * Static utility to extract raw PK value from a RecordID string.
     * Handles both single PK (raw value) and composite PK (concatenated) formats.
     * @param recordId The RecordID value from a ListDetail record
     * @param entityInfo The EntityInfo for the source entity
     * @returns For single PK: the raw value. For composite PK: the full concatenated string.
     */
    static ExtractPrimaryKeyValue(recordId: string, entityInfo: EntityInfo): string;
    Save(): Promise<boolean>;
}
//# sourceMappingURL=MJListDetailEntityExtended.d.ts.map