class MutableScopedDataSet extends MutableDataSet {
    protected final DataHolder parent;

    public MutableScopedDataSet(DataHolder parent) {
        super();
        this.parent = parent;
    }

    public MutableScopedDataSet(DataHolder parent, MutableDataHolder other) {
        super(other);
        this.parent = parent;
    }

    public DataHolder getParent() {
        return parent;
    }

    @Override
    public @NotNull Map<? extends DataKeyBase<?>, Object> getAll() {
        if (parent != null) {
            HashMap<DataKeyBase<?>, Object> all = new HashMap<>(super.getAll());
            for (DataKeyBase<?> key : parent.getKeys()) {
                if (!contains(key)) {
                    all.put(key, key.get(parent));
                }
            }

            return all;
        } else {
            return super.getAll();
        }
    }

    @Override
    public @NotNull Collection<? extends DataKeyBase<?>> getKeys() {<FILL_FUNCTION_BODY>}

    @Override
    public boolean contains(@NotNull DataKeyBase<?> key) {
        return super.contains(key) || (parent != null && parent.contains(key));
    }

    @Override
    public @Nullable Object getOrCompute(@NotNull DataKeyBase<?> key, @NotNull DataValueFactory<?> factory) {
        if (parent == null || super.contains(key) || !parent.contains(key)) {
            return super.getOrCompute(key, factory);
        } else {
            return parent.getOrCompute(key, factory);
        }
    }
}

        if (parent != null) {
            ArrayList<DataKeyBase<?>> all = new ArrayList<>(super.getKeys());
            for (DataKeyBase<?> key : parent.getKeys()) {
                if (!contains(key)) {
                    all.add(key);
                }
            }

            return all;
        } else {
            return super.getKeys();
        }
    
<methods>public void <init>() ,public void <init>(@Nullable DataHolder) ,public @NotNull MutableDataSet clear() ,public @Nullable Object getOrCompute(@NotNull DataKeyBase<?>, @NotNull DataValueFactory<?>) ,public static transient com.vladsch.flexmark.util.data.MutableDataSet merge(com.vladsch.flexmark.util.data.DataHolder[]) ,public @NotNull MutableDataSet remove(@NotNull DataKeyBase<?>) ,public @NotNull MutableDataSet set(@NotNull DataKey<T>, @NotNull T) ,public @NotNull MutableDataSet set(@NotNull NullableDataKey<T>, @Nullable T) ,public @NotNull MutableDataSet setAll(@NotNull DataHolder) ,public @NotNull MutableDataSet setFrom(@NotNull MutableDataSetter) ,public @NotNull MutableDataHolder setIn(@NotNull MutableDataHolder) ,public @NotNull MutableDataSet toDataSet() ,public @NotNull DataSet toImmutable() ,public @NotNull MutableDataSet toMutable() <variables>