class OakMachine {

    final void processSubpackage(final @NotNull Session admin,
                                 final @NotNull JcrPackageManager manager,
                                 final @NotNull PackageId packageId,
                                 final @NotNull PackageId parentId,
                                 final boolean preInstall) throws RepositoryException {
        internalProcessSubpackage(admin, manager, packageId, preInstall,
                () -> manager.open(packageId),
                check -> check.identifySubpackage(packageId, parentId),
                error -> getErrorListener().onSubpackageException(error, packageId));
    }

    private  OakMachine(final Packaging packagingService,
                       final List<ProgressCheck> progressChecks,
                       final ErrorListener errorListener,
                       final List<URL> preInstallUrls,
                       final List<InitStage> initStages,
                       final JcrCustomizer jcrCustomizer,
                       final InstallHookProcessorFactory installHookProcessorFactory,
                       final ClassLoader installHookClassLoader,
                       final boolean enablePreInstallHooks,
                       final InstallHookPolicy scanInstallHookPolicy,
                       final Supplier<NodeStore> nodeStoreSupplier,
                       final SubpackageSilencer subpackageSilencer,
                       final RepoInitProcessor repoInitProcessor,
                       final SlingSimulatorBackend slingSimulator,
                       final Set<String> runModes);

}