package be.selckin.swu.model;

import org.apache.wicket.model.IModel;

public abstract class ReadOnlyWrapLDM<T, W> extends ReadOnlyLDM<T> {
    protected final IModel<? extends W> wrapped;

    protected ReadOnlyWrapLDM(IModel<? extends W> wrapped) {
        this.wrapped = wrapped;
    }

    @Override
    protected void onDetach() {
        super.onDetach();
        wrapped.detach();
    }
}
