import { classifyLegacyPropertyKey, isContentCompatibilityClassification, requireLegacyPropertyKeyValue, } from "./LegacyPropertyKeyClassification.js";
/** Runtime-backed key for a legacy node property compatibility slot. */
export default class LegacyNodePropertyKey {
    value;
    constructor(value) {
        this.value = requireLegacyPropertyKeyValue(value, 'LegacyNodePropertyKey');
        Object.freeze(this);
    }
    /** Returns the stable legacy property key string. */
    toString() {
        return this.value;
    }
    /** Classifies this key for compatibility projection decisions. */
    classification() {
        return classifyLegacyPropertyKey(this.value);
    }
    /** Returns true when this key belongs to legacy content compatibility. */
    isContentCompatibilityKey() {
        return isContentCompatibilityClassification(this.classification());
    }
    /** Compares node property keys by runtime value. */
    equals(other) {
        if (!(other instanceof LegacyNodePropertyKey)) {
            return false;
        }
        return this.value === other.value;
    }
}
