All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.oracle.graal.python.PythonLanguageProvider Maven / Gradle / Ivy

There is a newer version: 24.1.1
Show newest version
// CheckStyle: start generated
package com.oracle.graal.python;

import com.oracle.truffle.api.TruffleLanguage.ContextPolicy;
import com.oracle.truffle.api.TruffleLanguage.Registration;
import com.oracle.truffle.api.debug.DebuggerTags.AlwaysHalt;
import com.oracle.truffle.api.dsl.GeneratedBy;
import com.oracle.truffle.api.instrumentation.ProvidedTags;
import com.oracle.truffle.api.instrumentation.StandardTags.CallTag;
import com.oracle.truffle.api.instrumentation.StandardTags.ExpressionTag;
import com.oracle.truffle.api.instrumentation.StandardTags.ReadVariableTag;
import com.oracle.truffle.api.instrumentation.StandardTags.RootBodyTag;
import com.oracle.truffle.api.instrumentation.StandardTags.RootTag;
import com.oracle.truffle.api.instrumentation.StandardTags.StatementTag;
import com.oracle.truffle.api.instrumentation.StandardTags.TryBlockTag;
import com.oracle.truffle.api.instrumentation.StandardTags.WriteVariableTag;
import com.oracle.truffle.api.provider.TruffleLanguageProvider;
import java.util.Collection;
import java.util.List;

@GeneratedBy(PythonLanguage.class)
@Registration(byteMimeTypes = "application/x-python-bytecode", characterMimeTypes = {"text/x-python", "text/x-python--eval", "text/x-python--compile", "text/x-python--eval", "text/x-python--compile", "text/x-python--eval", "text/x-python--compile", "text/x-python-Ā-eval", "text/x-python-Ā-compile", "text/x-python-Ā-eval", "text/x-python-Ā-compile", "text/x-python-Ā-eval", "text/x-python-Ā-compile", "text/x-python-@-eval", "text/x-python-@-compile", "text/x-python-@-eval", "text/x-python-@-compile", "text/x-python-@-eval", "text/x-python-@-compile", "text/x-python-ŀ-eval", "text/x-python-ŀ-compile", "text/x-python-ŀ-eval", "text/x-python-ŀ-compile", "text/x-python-ŀ-eval", "text/x-python-ŀ-compile"}, contextPolicy = ContextPolicy.SHARED, defaultMimeType = "text/x-python", dependentLanguages = {"nfi", "llvm"}, id = "python", implementationName = "GraalPy", interactive = true, internal = false, name = "Python", version = "3.10.8", website = "https://www.graalvm.org/python/")
@ProvidedTags({CallTag.class, StatementTag.class, RootTag.class, RootBodyTag.class, TryBlockTag.class, ExpressionTag.class, ReadVariableTag.class, WriteVariableTag.class, AlwaysHalt.class})
public final class PythonLanguageProvider extends TruffleLanguageProvider {

    @Override
    protected String getLanguageClassName() {
        return "com.oracle.graal.python.PythonLanguage";
    }

    @Override
    protected Object create() {
        return new PythonLanguage();
    }

    @Override
    protected Collection getServicesClassNames() {
        return List.of();
    }

    @Override
    protected List createFileTypeDetectors() {
        return List.of(new PythonFileDetector());
    }

    @Override
    protected List getInternalResourceIds() {
        return List.of();
    }

    @Override
    protected Object createInternalResource(String resourceId) {
        throw new IllegalArgumentException(String.format("Unsupported internal resource id %s, supported ids are ", resourceId));
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy