com.oracle.truffle.sl.SLLanguageProvider Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of truffle-sl Show documentation
Show all versions of truffle-sl Show documentation
Truffle SL is an example language implemented using the Truffle API.
The newest version!
// CheckStyle: start generated
package com.oracle.truffle.sl;
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.WriteVariableTag;
import com.oracle.truffle.api.provider.TruffleLanguageProvider;
import java.util.Collection;
import java.util.List;
@GeneratedBy(SLLanguage.class)
@Registration(characterMimeTypes = "application/x-sl", contextPolicy = ContextPolicy.SHARED, defaultMimeType = "application/x-sl", id = "sl", name = "SL", website = "https://www.graalvm.org/graalvm-as-a-platform/implement-language/")
@ProvidedTags({CallTag.class, StatementTag.class, RootTag.class, RootBodyTag.class, ExpressionTag.class, AlwaysHalt.class, ReadVariableTag.class, WriteVariableTag.class})
public final class SLLanguageProvider extends TruffleLanguageProvider {
@Override
protected String getLanguageClassName() {
return "com.oracle.truffle.sl.SLLanguage";
}
@Override
protected Object create() {
return new SLLanguage();
}
@Override
protected Collection getServicesClassNames() {
return List.of();
}
@Override
protected List> createFileTypeDetectors() {
return List.of(new SLFileDetector());
}
@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