Search in sources :

Example 1 with MemoryFileManager

use of org.finos.legend.pure.runtime.java.compiled.compiler.MemoryFileManager in project legend-pure by finos.

the class CompiledSupport method dynamicallyEvaluateValueSpecification.

public static Object dynamicallyEvaluateValueSpecification(final CoreInstance valueSpecification, PureMap lambdaOpenVariablesMap, ExecutionSupport es) {
    MemoryFileManager fileManager = ((CompiledExecutionSupport) es).getMemoryFileManager();
    ClassLoader globalClassLoader = ((CompiledExecutionSupport) es).getClassLoader();
    final CompiledProcessorSupport compiledSupport = new CompiledProcessorSupport(globalClassLoader, ((CompiledExecutionSupport) es).getMetadata(), ((CompiledExecutionSupport) es).getExtraSupportedTypes());
    final ProcessorContext processorContext = new ProcessorContext(compiledSupport);
    // Don't do anything if the ValueSpecification is already resolved ----------------
    if (Instance.instanceOf(valueSpecification, M3Paths.InstanceValue, processorContext.getSupport())) {
        ListIterable<? extends CoreInstance> l = valueSpecification.getValueForMetaPropertyToMany(M3Properties.values);
        if (l.noneSatisfy(instance -> Instance.instanceOf(instance, M3Paths.ValueSpecification, processorContext.getSupport()) || Instance.instanceOf(instance, M3Paths.LambdaFunction, processorContext.getSupport()))) {
            ListIterable<Object> result = l.collect(instance -> instance instanceof ValCoreInstance ? ((ValCoreInstance) instance).getValue() : instance);
            return result.size() == 1 ? result.get(0) : result;
        }
    }
    // ---------------------------------------------------------------------------------
    processorContext.setInLineAllLambda(true);
    String processed = ValueSpecificationProcessor.processValueSpecification(valueSpecification, true, processorContext);
    String returnType = TypeProcessor.typeToJavaObjectWithMul(valueSpecification.getValueForMetaPropertyToOne(M3Properties.genericType), valueSpecification.getValueForMetaPropertyToOne(M3Properties.multiplicity), false, compiledSupport);
    String name = "DynaClass";
    RichIterable<Pair<String, CoreInstance>> values = lambdaOpenVariablesMap.getMap().keyValuesView();
    final MutableMap<String, Object> openVars = Maps.mutable.of();
    String _class = JavaSourceCodeGenerator.imports + "\npublic class " + name + "{\n" + "   public static " + returnType + " doProcess(final MapIterable<String, Object> vars, final MutableMap<String, Object> valMap, final IntObjectMap<CoreInstance> localLambdas, final ExecutionSupport es){\n" + values.collect(new Function<Pair<String, CoreInstance>, String>() {

        @Override
        public String valueOf(Pair<String, CoreInstance> pair) {
            final String name = pair.getOne();
            CoreInstance valuesCoreInstance = pair.getTwo();
            ListIterable<? extends CoreInstance> values = valuesCoreInstance.getValueForMetaPropertyToMany(M3Properties.values).select(coreInstance -> !Instance.instanceOf(coreInstance, "meta::pure::executionPlan::PlanVarPlaceHolder", compiledSupport) && !Instance.instanceOf(coreInstance, "meta::pure::executionPlan::PlanVariablePlaceHolder", compiledSupport));
            String type = null;
            openVars.put(name, valuesCoreInstance);
            if (values.isEmpty()) {
                MutableList<CoreInstance> vars = FastList.newList();
                collectVars(valueSpecification, vars, compiledSupport);
                CoreInstance found = vars.detect(coreInstance -> coreInstance.getValueForMetaPropertyToOne("name").getName().equals(name));
                if (found != null) {
                    type = TypeProcessor.typeToJavaObjectSingle(found.getValueForMetaPropertyToOne(M3Properties.genericType), false, compiledSupport);
                    return "      final  " + type + "  _" + name + " = null;";
                }
                return "";
            } else {
                type = TypeProcessor.pureRawTypeToJava(compiledSupport.getClassifier(values.getFirst()), false, compiledSupport);
                final String listImpl = JavaPackageAndImportBuilder.buildImplClassReferenceFromUserPath(M3Paths.List);
                return (values.size() == 1) ? ("      final " + type + " _" + name + " = (" + type + ")((" + listImpl + ")vars.get(\"" + name + "\"))._values.getFirst();") : ("      final RichIterable<" + type + "> _" + name + " = ((" + listImpl + ")vars.get(\"" + name + "\"))._values;");
            }
        }
    }).makeString("\n") + "       return " + processed + ";\n" + "   }\n" + "}\n";
    String javaPackage = JavaPackageAndImportBuilder.buildPackageForPackageableElement(valueSpecification);
    ListIterable<StringJavaSource> javaClasses = Lists.immutable.with(StringJavaSource.newStringJavaSource(javaPackage, name, _class));
    JavaCompiler compiler = ToolProvider.getSystemJavaCompiler();
    MemoryFileManager manager = new MemoryFileManager(compiler, fileManager, null);
    try {
        PureJavaCompiler.compile(compiler, javaClasses, manager);
    } catch (Exception e) {
        StringBuilder message = new StringBuilder("Error dynamically evaluating value specification");
        SourceInformation valueSpecSourceInfo = valueSpecification.getSourceInformation();
        if (valueSpecSourceInfo != null) {
            valueSpecSourceInfo.appendMessage(message.append(" (from ")).append(')');
        }
        message.append("; error compiling generated Java code:\n").append(_class);
        throw new RuntimeException(message.toString(), e);
    }
    ClassLoader cl = new MemoryClassLoader(manager, globalClassLoader);
    try {
        Class<?> realClass = cl.loadClass(javaPackage + "." + name);
        return realClass.getMethod("doProcess", MapIterable.class, MutableMap.class, IntObjectMap.class, ExecutionSupport.class).invoke(null, openVars, processorContext.getObjectToPassToDynamicallyGeneratedCode(), processorContext.getLocalLambdas(), es);
    } catch (Exception e) {
        StringBuilder message = new StringBuilder("Error dynamically evaluating value specification");
        SourceInformation valueSpecSourceInfo = valueSpecification.getSourceInformation();
        if (valueSpecSourceInfo != null) {
            valueSpecSourceInfo.appendMessage(message.append(" (from ")).append(')');
        }
        String errorMessage = e.getMessage();
        if (errorMessage != null) {
            message.append(": ").append(errorMessage);
        }
        throw new RuntimeException(message.toString(), e);
    }
}
Also used : MutableMap(org.eclipse.collections.api.map.MutableMap) ProcessorContext(org.finos.legend.pure.runtime.java.compiled.generation.ProcessorContext) CompiledProcessorSupport(org.finos.legend.pure.runtime.java.compiled.execution.CompiledProcessorSupport) SharedPureFunction(org.finos.legend.pure.runtime.java.compiled.generation.processors.support.function.SharedPureFunction) Function(org.eclipse.collections.api.block.function.Function) JavaMethodWithParamsSharedPureFunction(org.finos.legend.pure.runtime.java.compiled.metadata.JavaMethodWithParamsSharedPureFunction) IntObjectMap(org.eclipse.collections.api.map.primitive.IntObjectMap) MemoryClassLoader(org.finos.legend.pure.runtime.java.compiled.compiler.MemoryClassLoader) CompiledExecutionSupport(org.finos.legend.pure.runtime.java.compiled.execution.CompiledExecutionSupport) ExecutionSupport(org.finos.legend.pure.m3.execution.ExecutionSupport) StringJavaSource(org.finos.legend.pure.runtime.java.compiled.compiler.StringJavaSource) MemoryClassLoader(org.finos.legend.pure.runtime.java.compiled.compiler.MemoryClassLoader) MemoryFileManager(org.finos.legend.pure.runtime.java.compiled.compiler.MemoryFileManager) Pair(org.eclipse.collections.api.tuple.Pair) ValCoreInstance(org.finos.legend.pure.runtime.java.compiled.generation.processors.support.coreinstance.ValCoreInstance) JavaCompiler(javax.tools.JavaCompiler) PureJavaCompiler(org.finos.legend.pure.runtime.java.compiled.compiler.PureJavaCompiler) MapIterable(org.eclipse.collections.api.map.MapIterable) PureAssertFailException(org.finos.legend.pure.m3.exception.PureAssertFailException) InvalidFunctionDescriptorException(org.finos.legend.pure.m3.navigation.function.InvalidFunctionDescriptorException) InvocationTargetException(java.lang.reflect.InvocationTargetException) PureJavaCompileException(org.finos.legend.pure.runtime.java.compiled.compiler.PureJavaCompileException) PureException(org.finos.legend.pure.m4.exception.PureException) PureExecutionException(org.finos.legend.pure.m3.exception.PureExecutionException) ParseException(org.json.simple.parser.ParseException) NoSuchElementException(java.util.NoSuchElementException) SourceInformation(org.finos.legend.pure.m4.coreinstance.SourceInformation) CompiledExecutionSupport(org.finos.legend.pure.runtime.java.compiled.execution.CompiledExecutionSupport) CoreInstance(org.finos.legend.pure.m4.coreinstance.CoreInstance) ValCoreInstance(org.finos.legend.pure.runtime.java.compiled.generation.processors.support.coreinstance.ValCoreInstance) BaseCoreInstance(org.finos.legend.pure.m3.coreinstance.BaseCoreInstance) ReflectiveCoreInstance(org.finos.legend.pure.runtime.java.compiled.generation.processors.support.coreinstance.ReflectiveCoreInstance) AbstractCoreInstance(org.finos.legend.pure.m4.coreinstance.AbstractCoreInstance) JavaCompiledCoreInstance(org.finos.legend.pure.runtime.java.compiled.generation.processors.support.coreinstance.JavaCompiledCoreInstance)

Example 2 with MemoryFileManager

use of org.finos.legend.pure.runtime.java.compiled.compiler.MemoryFileManager in project legend-pure by finos.

the class CompiledSupport method dynamicallyBuildLambdaFunction.

public static Object dynamicallyBuildLambdaFunction(CoreInstance lambdaFunction, ExecutionSupport es) {
    ClassLoader globalClassLoader = ((CompiledExecutionSupport) es).getClassLoader();
    CompiledProcessorSupport compiledSupport = new CompiledProcessorSupport(globalClassLoader, ((CompiledExecutionSupport) es).getMetadata(), ((CompiledExecutionSupport) es).getExtraSupportedTypes());
    ProcessorContext processorContext = new ProcessorContext(compiledSupport);
    processorContext.setInLineAllLambda(true);
    String name = "DynamicLambdaGeneration";
    String _class = JavaSourceCodeGenerator.imports + "\nimport " + JavaPackageAndImportBuilder.rootPackage() + ".*;\npublic class " + name + "{" + "   public static PureCompiledLambda build(final MutableMap<String, Object> valMap, final IntObjectMap<CoreInstance> localLambdas){\n" + "return " + ValueSpecificationProcessor.processLambda(null, lambdaFunction, compiledSupport, processorContext) + ";" + "}" + "}";
    MemoryFileManager fileManager = ((CompiledExecutionSupport) es).getMemoryFileManager();
    MutableList<StringJavaSource> javaClasses = FastList.newList();
    javaClasses.add(StringJavaSource.newStringJavaSource("temp", name, _class));
    JavaCompiler compiler = ToolProvider.getSystemJavaCompiler();
    MemoryFileManager manager = new MemoryFileManager(compiler, fileManager, null);
    try {
        PureJavaCompiler.compile(compiler, javaClasses, manager);
    } catch (PureJavaCompileException e) {
        throw new RuntimeException(e);
    }
    ClassLoader cl = new MemoryClassLoader(manager, globalClassLoader);
    try {
        Class<?> realClass = cl.loadClass("temp" + "." + name);
        return realClass.getMethod("build", MutableMap.class, IntObjectMap.class).invoke(null, processorContext.getObjectToPassToDynamicallyGeneratedCode(), processorContext.getLocalLambdas());
    } catch (Exception e) {
        throw new RuntimeException(e);
    }
}
Also used : MutableMap(org.eclipse.collections.api.map.MutableMap) JavaCompiler(javax.tools.JavaCompiler) PureJavaCompiler(org.finos.legend.pure.runtime.java.compiled.compiler.PureJavaCompiler) PureAssertFailException(org.finos.legend.pure.m3.exception.PureAssertFailException) InvalidFunctionDescriptorException(org.finos.legend.pure.m3.navigation.function.InvalidFunctionDescriptorException) InvocationTargetException(java.lang.reflect.InvocationTargetException) PureJavaCompileException(org.finos.legend.pure.runtime.java.compiled.compiler.PureJavaCompileException) PureException(org.finos.legend.pure.m4.exception.PureException) PureExecutionException(org.finos.legend.pure.m3.exception.PureExecutionException) ParseException(org.json.simple.parser.ParseException) NoSuchElementException(java.util.NoSuchElementException) ProcessorContext(org.finos.legend.pure.runtime.java.compiled.generation.ProcessorContext) CompiledProcessorSupport(org.finos.legend.pure.runtime.java.compiled.execution.CompiledProcessorSupport) IntObjectMap(org.eclipse.collections.api.map.primitive.IntObjectMap) PureJavaCompileException(org.finos.legend.pure.runtime.java.compiled.compiler.PureJavaCompileException) MemoryClassLoader(org.finos.legend.pure.runtime.java.compiled.compiler.MemoryClassLoader) CompiledExecutionSupport(org.finos.legend.pure.runtime.java.compiled.execution.CompiledExecutionSupport) StringJavaSource(org.finos.legend.pure.runtime.java.compiled.compiler.StringJavaSource) MemoryClassLoader(org.finos.legend.pure.runtime.java.compiled.compiler.MemoryClassLoader) MemoryFileManager(org.finos.legend.pure.runtime.java.compiled.compiler.MemoryFileManager)

Example 3 with MemoryFileManager

use of org.finos.legend.pure.runtime.java.compiled.compiler.MemoryFileManager in project legend-sdlc by finos.

the class TestServiceExecutionClassGenerator method compileGeneratedJavaClass.

private Class<?> compileGeneratedJavaClass(ServiceExecutionClassGenerator.GeneratedJavaClass generatedJavaClass) throws ClassNotFoundException {
    // System.out.format("%s%n-------------------------%n%s%n", generatedJavaClass.getName(), generatedJavaClass.getCode());
    JavaCompiler compiler = ToolProvider.getSystemJavaCompiler();
    DiagnosticCollector<JavaFileObject> diagnosticCollector = new DiagnosticCollector<>();
    MemoryFileManager fileManager = new MemoryFileManager(compiler);
    JavaCompiler.CompilationTask task = compiler.getTask(null, fileManager, diagnosticCollector, Arrays.asList("-classpath", CLASSPATH), null, Collections.singletonList(new GeneratedJavaFileObject(generatedJavaClass)));
    if (!task.call()) {
        Assert.fail(diagnosticCollector.getDiagnostics().toString());
    }
    return new MemoryClassLoader(fileManager, Thread.currentThread().getContextClassLoader()).loadClass(generatedJavaClass.getName());
}
Also used : SimpleJavaFileObject(javax.tools.SimpleJavaFileObject) JavaFileObject(javax.tools.JavaFileObject) MemoryClassLoader(org.finos.legend.pure.runtime.java.compiled.compiler.MemoryClassLoader) JavaCompiler(javax.tools.JavaCompiler) DiagnosticCollector(javax.tools.DiagnosticCollector) MemoryFileManager(org.finos.legend.pure.runtime.java.compiled.compiler.MemoryFileManager)

Example 4 with MemoryFileManager

use of org.finos.legend.pure.runtime.java.compiled.compiler.MemoryFileManager in project legend-sdlc by finos.

the class TestServiceExecutionGenerator method generateAndCompile.

private ClassLoader generateAndCompile(String packagePrefix, Collection<? extends Service> services) throws IOException {
    // Generate
    for (Service service : services) {
        ServiceExecutionGenerator.newGenerator(service, PURE_MODEL, packagePrefix, this.generatedSourcesDirectory, this.classesDirectory, null, core_relational_relational_router_router_extension.Root_meta_pure_router_extension_defaultRelationalExtensions__RouterExtension_MANY_(PURE_MODEL.getExecutionSupport()), LegendPlanTransformers.transformers, "vX_X_X").generate();
    }
    // Check generated files
    String separator = this.tmpFolder.getRoot().toPath().getFileSystem().getSeparator();
    // Check execution plan resources generated
    Set<String> expectedResources = services.stream().map(s -> "plans" + separator + getPackagePrefix(packagePrefix, separator) + s.getPath().replace("::", separator) + ".json").collect(Collectors.toSet());
    expectedResources.add("META-INF" + separator + "services" + separator + ServiceRunner.class.getCanonicalName());
    Set<String> actualResources = Files.walk(this.classesDirectory, Integer.MAX_VALUE).filter(Files::isRegularFile).map(this.classesDirectory::relativize).map(Path::toString).collect(Collectors.toSet());
    Assert.assertEquals(expectedResources, actualResources);
    // Check class files generated
    Set<String> expectedServiceJavaSources = services.stream().map(s -> getPackagePrefix(packagePrefix, separator) + s.getPath().replace("::", separator) + ".java").collect(Collectors.toSet());
    Set<String> actualJavaSources = Files.walk(this.generatedSourcesDirectory, Integer.MAX_VALUE).map(this.generatedSourcesDirectory::relativize).map(Path::toString).filter(s -> s.endsWith(".java")).collect(Collectors.toSet());
    if (!actualJavaSources.containsAll(expectedServiceJavaSources)) {
        Assert.fail(expectedServiceJavaSources.stream().filter(c -> !actualJavaSources.contains(c)).sorted().collect(Collectors.joining(", ", "Missing Java sources: ", "")));
    }
    // Compile
    JavaCompiler compiler = ToolProvider.getSystemJavaCompiler();
    DiagnosticCollector<JavaFileObject> diagnosticCollector = new DiagnosticCollector<>();
    MemoryFileManager fileManager = new MemoryFileManager(compiler);
    List<SourceFile> javaSources = Files.walk(this.generatedSourcesDirectory, Integer.MAX_VALUE).filter(p -> p.getFileName().toString().endsWith(".java")).map(SourceFile::new).collect(Collectors.toList());
    JavaCompiler.CompilationTask task = compiler.getTask(null, fileManager, diagnosticCollector, Arrays.asList("-classpath", CLASSPATH), null, javaSources);
    if (!task.call()) {
        Assert.fail(diagnosticCollector.getDiagnostics().toString());
    }
    fileManager.writeClassJavaSources(this.classesDirectory, false);
    // Create new classloader and check that everything expected is present
    ClassLoader classLoader = new URLClassLoader(new URL[] { this.classesDirectory.toUri().toURL() }, Thread.currentThread().getContextClassLoader());
    // Check plan resources
    List<String> missingPlanResources = services.stream().map(s -> "plans/" + getPackagePrefix(packagePrefix, "/") + s.getPath().replace("::", "/") + ".json").filter(n -> classLoader.getResource(n) == null).sorted().collect(Collectors.toList());
    Assert.assertEquals(Collections.emptyList(), missingPlanResources);
    // Check service execution classes
    List<String> missingServiceExecutionClasses = services.stream().map(s -> getPackagePrefix(packagePrefix, ".") + s.getPath().replace("::", ".")).filter(n -> {
        try {
            classLoader.loadClass(n);
            return false;
        } catch (ClassNotFoundException e) {
            return true;
        }
    }).sorted().collect(Collectors.toList());
    Assert.assertEquals(Collections.emptyList(), missingServiceExecutionClasses);
    // Check ServiceRunner provider configuration file
    InputStream serviceRunnerResourceStream = classLoader.getResourceAsStream("META-INF" + separator + "services" + separator + ServiceRunner.class.getCanonicalName());
    Assert.assertNotNull("ServiceRunner provider configuration file missing", serviceRunnerResourceStream);
    List<String> serviceRunnerProviders = new BufferedReader(new InputStreamReader(serviceRunnerResourceStream)).lines().collect(Collectors.toList());
    List<String> missingServiceProviders = services.stream().map(PackageableElement::getPath).filter(path -> !serviceRunnerProviders.contains(getPackagePrefix(packagePrefix, ".") + path.replace("::", "."))).sorted().collect(Collectors.toList());
    Assert.assertEquals(Collections.emptyList(), missingServiceProviders);
    return classLoader;
}
Also used : ClassGraph(io.github.classgraph.ClassGraph) Arrays(java.util.Arrays) AbstractServicePlanExecutor(org.finos.legend.engine.language.pure.dsl.service.execution.AbstractServicePlanExecutor) URL(java.net.URL) Spliterators(java.util.Spliterators) ZonedDateTime(java.time.ZonedDateTime) SerializationFormat(org.finos.legend.engine.plan.execution.result.serialization.SerializationFormat) StreamProvider(org.finos.legend.engine.shared.core.url.StreamProvider) ServiceRunner(org.finos.legend.engine.language.pure.dsl.service.execution.ServiceRunner) BigDecimal(java.math.BigDecimal) URLClassLoader(java.net.URLClassLoader) EntityLoader(org.finos.legend.sdlc.serialization.EntityLoader) PureModelContextData(org.finos.legend.engine.protocol.pure.v1.model.context.PureModelContextData) Map(java.util.Map) JsonNode(com.fasterxml.jackson.databind.JsonNode) Multiplicity(org.finos.legend.engine.protocol.pure.v1.model.packageableElement.domain.Multiplicity) DiagnosticCollector(javax.tools.DiagnosticCollector) Method(java.lang.reflect.Method) Path(java.nio.file.Path) SimpleJavaFileObject(javax.tools.SimpleJavaFileObject) PureModel(org.finos.legend.engine.language.pure.compiler.toPureGraph.PureModel) AfterClass(org.junit.AfterClass) JavaCompiler(javax.tools.JavaCompiler) Collection(java.util.Collection) Set(java.util.Set) ServiceLoader(java.util.ServiceLoader) Iterate(org.eclipse.collections.impl.utility.Iterate) Collectors(java.util.stream.Collectors) JsonStreamingResult(org.finos.legend.engine.plan.execution.result.json.JsonStreamingResult) StandardCharsets(java.nio.charset.StandardCharsets) ZoneId(java.time.ZoneId) JavaFileObject(javax.tools.JavaFileObject) Objects(java.util.Objects) ServiceRunnerInput(org.finos.legend.engine.language.pure.dsl.service.execution.ServiceRunnerInput) List(java.util.List) Service(org.finos.legend.engine.protocol.pure.v1.model.packageableElement.service.Service) LocalDate(java.time.LocalDate) Temporal(java.time.temporal.Temporal) Spliterator(java.util.Spliterator) ToolProvider(javax.tools.ToolProvider) PackageableElement(org.finos.legend.engine.protocol.pure.v1.model.packageableElement.PackageableElement) BeforeClass(org.junit.BeforeClass) MemoryFileManager(org.finos.legend.pure.runtime.java.compiled.compiler.MemoryFileManager) LocalDateTime(java.time.LocalDateTime) org.finos.legend.pure.generated.core_relational_relational_router_router_extension(org.finos.legend.pure.generated.core_relational_relational_router_router_extension) ServiceVariable(org.finos.legend.engine.language.pure.dsl.service.execution.ServiceVariable) JavaHelper(org.finos.legend.engine.plan.execution.nodes.helpers.platform.JavaHelper) StreamSupport(java.util.stream.StreamSupport) PureModelBuilder(org.finos.legend.sdlc.language.pure.compiler.toPureGraph.PureModelBuilder) Before(org.junit.Before) Result(org.finos.legend.engine.plan.execution.result.Result) Files(java.nio.file.Files) ObjectMapper(com.fasterxml.jackson.databind.ObjectMapper) Test(org.junit.Test) IOException(java.io.IOException) InputStreamReader(java.io.InputStreamReader) Rule(org.junit.Rule) Paths(java.nio.file.Paths) LegendPlanTransformers(org.finos.legend.engine.plan.generation.transformers.LegendPlanTransformers) BufferedReader(java.io.BufferedReader) Assert(org.junit.Assert) Collections(java.util.Collections) TemporaryFolder(org.junit.rules.TemporaryFolder) InputStream(java.io.InputStream) Path(java.nio.file.Path) InputStreamReader(java.io.InputStreamReader) InputStream(java.io.InputStream) Service(org.finos.legend.engine.protocol.pure.v1.model.packageableElement.service.Service) JavaCompiler(javax.tools.JavaCompiler) SimpleJavaFileObject(javax.tools.SimpleJavaFileObject) JavaFileObject(javax.tools.JavaFileObject) URLClassLoader(java.net.URLClassLoader) BufferedReader(java.io.BufferedReader) URLClassLoader(java.net.URLClassLoader) DiagnosticCollector(javax.tools.DiagnosticCollector) MemoryFileManager(org.finos.legend.pure.runtime.java.compiled.compiler.MemoryFileManager)

Aggregations

JavaCompiler (javax.tools.JavaCompiler)4 MemoryFileManager (org.finos.legend.pure.runtime.java.compiled.compiler.MemoryFileManager)4 InvocationTargetException (java.lang.reflect.InvocationTargetException)2 NoSuchElementException (java.util.NoSuchElementException)2 DiagnosticCollector (javax.tools.DiagnosticCollector)2 JavaFileObject (javax.tools.JavaFileObject)2 SimpleJavaFileObject (javax.tools.SimpleJavaFileObject)2 MutableMap (org.eclipse.collections.api.map.MutableMap)2 IntObjectMap (org.eclipse.collections.api.map.primitive.IntObjectMap)2 PureAssertFailException (org.finos.legend.pure.m3.exception.PureAssertFailException)2 PureExecutionException (org.finos.legend.pure.m3.exception.PureExecutionException)2 InvalidFunctionDescriptorException (org.finos.legend.pure.m3.navigation.function.InvalidFunctionDescriptorException)2 PureException (org.finos.legend.pure.m4.exception.PureException)2 MemoryClassLoader (org.finos.legend.pure.runtime.java.compiled.compiler.MemoryClassLoader)2 PureJavaCompileException (org.finos.legend.pure.runtime.java.compiled.compiler.PureJavaCompileException)2 PureJavaCompiler (org.finos.legend.pure.runtime.java.compiled.compiler.PureJavaCompiler)2 StringJavaSource (org.finos.legend.pure.runtime.java.compiled.compiler.StringJavaSource)2 CompiledExecutionSupport (org.finos.legend.pure.runtime.java.compiled.execution.CompiledExecutionSupport)2 CompiledProcessorSupport (org.finos.legend.pure.runtime.java.compiled.execution.CompiledProcessorSupport)2 ProcessorContext (org.finos.legend.pure.runtime.java.compiled.generation.ProcessorContext)2