public void testFail() {
   Resource root = resourceInModel("x rdf:type A");
   AssemblerGroup g = AssemblerGroup.create();
   g.implementWith(resource("A"), new ShantAssemble());
   try {
     g.open(root);
     fail("shouldn't get past exception");
   } catch (AssemblerException e) {
     AssemblerGroup.Frame frame =
         new AssemblerGroup.Frame(resource("x"), resource("A"), ShantAssemble.class);
     assertEquals(listOfOne(frame), e.getDoing());
   }
 }
Example #2
0
 /**
  * Register this assembler in the assembler group.
  *
  * @param group The assembler group to register with.
  */
 static void registerWith(AssemblerGroup group) {
   if (group == null) group = Assembler.general;
   group.implementWith(SECURED_MODEL, new SecuredAssembler());
 }
Example #3
0
 private static void assemblerClass(AssemblerGroup g, Resource r, Assembler a) {
   g.implementWith(r, a);
 }
Example #4
0
 public static void register(AssemblerGroup g) {
   // Wire in the extension assemblers (extensions relative to the Jena assembler framework)
   g.implementWith(DataSourceAssembler.getType(), new DataSourceAssembler());
   g.implementWith(GraphStoreAssembler.getType(), new GraphStoreAssembler());
 }