コード例 #1
0
  @Override
  protected SchemaTree rawProcess(final ProcessingReport report, final String input)
      throws ProcessingException {
    final ValueHolder<String> holder = ValueHolder.hold("source", input);
    final CompilerOutput compilerOutput = compiler.process(report, holder);

    try {
      final ValueHolder<Class<?>> input1 = extractClass(compilerOutput);
      return report.isSuccess() ? classToSchema.process(report, input1).getValue() : null;
    } finally {
      final String dir = compilerOutput.getDirectory().getDirectory();
      rmDashRf(new File(dir));
    }
  }
コード例 #2
0
 private static ValueHolder<Class<?>> extractClass(final CompilerOutput compilerOutput)
     throws CompilingException {
   final Class<?> c = compilerOutput.getGeneratedClass();
   return ValueHolder.<Class<?>>hold("class", c);
 }