import type { DocumentContext } from "../document/index.js";
import type { JsonValue, JsonValueType } from "./jsonTypes.js";
export declare abstract class AbstractJsonable {
    readonly probability: number | undefined;
    readonly weight: number | undefined;
    abstract readonly type: JsonValueType;
    protected constructor(probability: number | undefined, weight: number | undefined);
    protected testProbability(keyOrIndex: string | number, context: DocumentContext): boolean;
    protected abstract toJSONImpl(keyOrIndex: string | number, context: DocumentContext): JsonValue | undefined;
    toJSON(keyOrIndex: string | number, context: DocumentContext): JsonValue | undefined;
}
