@Test public void testBindParserProcessor_realDefaults() throws Exception { final OakMachine.RepoInitProcessor processor = DefaultRepoInitFactory.bindParser(new RepoInitParserService()); new OakMachine.Builder().build().adminInitAndInspect(admin -> { try (Reader reader = readSlingExampleRepoInit()) { processor.apply(admin, reader); } }); }
public static OakMachine.RepoInitProcessor bindParser(final @NotNull RepoInitParser parser) { final JcrRepoInitOpsProcessor processor = newOpsProcessor(); return (admin, reader) -> { final List<Operation> parsed = parser.parse(reader); processor.apply(admin, parsed); }; }
DefaultRepoInitFactory { public static OakMachine.RepoInitProcessor bindParser(final @NotNull RepoInitParser parser) { final JcrRepoInitOpsProcessor processor = newOpsProcessor(); return (admin, reader) -> { final List<Operation> parsed = parser.parse(reader); processor.apply(admin, parsed); }; } }
DefaultRepoInitFactory { public static OakMachine.RepoInitProcessor bindParser(final @NotNull RepoInitParser parser) { final JcrRepoInitOpsProcessor processor = newOpsProcessor(); return (admin, reader) -> { final List<Operation> parsed = parser.parse(reader); processor.apply(admin, parsed); }; } DefaultRepoInitFactory(final @Nullable Class<? extends RepoInitParser> parserClazz); }
DefaultRepoInitFactory { public static OakMachine.RepoInitProcessor bindParser(final @NotNull RepoInitParser parser) { final JcrRepoInitOpsProcessor processor = newOpsProcessor(); return (admin, reader) -> { final List<Operation> parsed = parser.parse(reader); processor.apply(admin, parsed); }; } DefaultRepoInitFactory(final @Nullable Class<? extends RepoInitParser> parserClazz); static DefaultRepoInitFactory newFactoryInstance(final @NotNull ClassLoader parserCl); static OakMachine.RepoInitProcessor newDefaultRepoInitProcessor(
            final @NotNull ClassLoader defaultClassLoader); static OakMachine.RepoInitProcessor bindParser(final @NotNull RepoInitParser parser); }
DefaultRepoInitFactory { public static OakMachine.RepoInitProcessor bindParser(final @NotNull RepoInitParser parser) { final JcrRepoInitOpsProcessor processor = newOpsProcessor(); return (admin, reader) -> { final List<Operation> parsed = parser.parse(reader); processor.apply(admin, parsed); }; } DefaultRepoInitFactory(final @Nullable Class<? extends RepoInitParser> parserClazz); static DefaultRepoInitFactory newFactoryInstance(final @NotNull ClassLoader parserCl); static OakMachine.RepoInitProcessor newDefaultRepoInitProcessor(
            final @NotNull ClassLoader defaultClassLoader); static OakMachine.RepoInitProcessor bindParser(final @NotNull RepoInitParser parser);  }