congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
TruffleLanguage$AccessAPI.engineAccess
Code IndexAdd Tabnine to your IDE (free)

How to use
engineAccess
method
in
com.oracle.truffle.api.TruffleLanguage$AccessAPI

Best Java code snippets using com.oracle.truffle.api.TruffleLanguage$AccessAPI.engineAccess (Showing top 20 results out of 315)

origin: org.graalvm.truffle/truffle-api

synchronized void removeLogLevelsForContext(final Object context) {
  final Set<String> toRemove = collectRemovedLevels();
  for (Iterator<ContextWeakReference> it = activeContexts.iterator(); it.hasNext();) {
    final Object activeContext = it.next().get();
    if (context.equals(activeContext)) {
      toRemove.addAll(TruffleLanguage.AccessAPI.engineAccess().getLogLevels(context).keySet());
      it.remove();
      break;
    }
  }
  reconfigure(Collections.emptyMap(), toRemove);
}
origin: com.oracle.truffle/truffle-api

void checkDisposed() {
  if (AccessAPI.engineAccess().isDisposed(vmObject)) {
    throw new IllegalStateException("Language environment is already disposed.");
  }
  if (!valid) {
    throw new IllegalStateException("Language environment is already invalidated.");
  }
}
origin: org.graalvm.truffle/truffle-api

void checkDisposed() {
  if (AccessAPI.engineAccess().isDisposed(vmObject)) {
    throw new IllegalStateException("Language environment is already disposed.");
  }
  if (!valid) {
    throw new IllegalStateException("Language environment is already invalidated.");
  }
}
origin: org.graalvm.truffle/truffle-api

/**
 * Returns <code>true</code> if host access is generally allowed. If this method returns
 * <code>false</code> then {@link #lookupHostSymbol(String)} will always fail.
 *
 * @since 0.27
 */
@TruffleBoundary
public boolean isHostLookupAllowed() {
  return AccessAPI.engineAccess().isHostAccessAllowed(vmObject, this);
}
origin: com.oracle.truffle/truffle-api

/**
 * Returns a map mime-type to language instance of all languages that are installed in the
 * environment. Using the language instance additional services can be
 * {@link #lookup(LanguageInfo, Class) looked up} .
 *
 * @since 0.26
 */
@TruffleBoundary
public Map<String, LanguageInfo> getLanguages() {
  return AccessAPI.engineAccess().getLanguages(vmObject);
}
origin: com.oracle.truffle/truffle-api

/**
 * Returns <code>true</code> if the creation of new threads is allowed in the current
 * environment.
 *
 * @see #createThread(Runnable)
 * @since 0.28
 */
public boolean isCreateThreadAllowed() {
  return AccessAPI.engineAccess().isCreateThreadAllowed(vmObject);
}
origin: org.graalvm.truffle/truffle-api

private TruffleContext(TruffleLanguage.Env env, Map<String, Object> config) {
  this.impl = AccessAPI.engineAccess().createInternalContext(env.getVMObject(), config, this);
  this.closeable = false;
  // Initialized after this TruffleContext instance is fully set up
  AccessAPI.engineAccess().initializeInternalContext(env.getVMObject(), impl);
}
origin: org.graalvm.truffle/truffle-api

/**
 * Converts a Java class to a host symbol as if by
 * {@code lookupHostSymbol(symbolClass.getName())} but without an actual lookup. Must not be
 * used with Truffle or guest language classes.
 *
 * @see #lookupHostSymbol(String)
 * @since 1.0
 */
@TruffleBoundary
public Object asHostSymbol(Class<?> symbolClass) {
  return AccessAPI.engineAccess().asHostSymbol(vmObject, symbolClass);
}
origin: org.graalvm.truffle/truffle-api

/**
 * Returns <code>true</code> if the argument is a Java host language function wrapped using
 * Truffle interop.
 *
 * @since 1.0
 */
@SuppressWarnings("static-method")
public boolean isHostFunction(Object value) {
  return AccessAPI.engineAccess().isHostFunction(value);
}
origin: com.oracle.truffle/truffle-api

/**
 * Returns the polyglot context associated with this environment.
 *
 * @return the polyglot context
 * @since 0.30
 */
public TruffleContext getContext() {
  return AccessAPI.engineAccess().getPolyglotContext(vmObject);
}
origin: com.oracle.truffle/truffle-api

/**
 * Returns a map instrument-id to instrument instance of all instruments that are installed
 * in the environment. Using the instrument instance additional services can be
 * {@link #lookup(InstrumentInfo, Class) looked up} .
 *
 * @since 0.26
 */
@TruffleBoundary
public Map<String, InstrumentInfo> getInstruments() {
  return AccessAPI.engineAccess().getInstruments(vmObject);
}
origin: com.oracle.truffle/truffle-api

/**
 * @since 0.8 or earlier
 * @deprecated in 0.25 use {@link #getContextReference()} instead
 */
@Deprecated
protected final Node createFindContextNode() {
  return AccessAPI.engineAccess().createFindContextNode(this);
}
origin: com.oracle.truffle/truffle-api

/**
 * Get a parent context of this context, if any. This provides the hierarchy of inner contexts.
 *
 * @return a parent context, or <code>null</code> if there is no parent
 * @since 0.30
 */
@TruffleBoundary
public TruffleContext getParent() {
  return AccessAPI.engineAccess().getParentContext(impl);
}
origin: org.graalvm.truffle/truffle-api

private <T extends Throwable> RuntimeException wrapHostException(T t) {
  if (TruffleLanguage.AccessAPI.engineAccess().isDefaultFileSystem(fileSystem)) {
    throw sthrow(t);
  }
  throw TruffleLanguage.AccessAPI.engineAccess().wrapHostException(TruffleLanguage.AccessAPI.engineAccess().getCurrentHostContext(), t);
}
origin: org.graalvm.truffle/truffle-api

/**
 * Returns the polyglot context associated with this environment.
 *
 * @return the polyglot context
 * @since 0.30
 */
public TruffleContext getContext() {
  return AccessAPI.engineAccess().getPolyglotContext(vmObject);
}
origin: org.graalvm.truffle/truffle-api

/**
 * Returns a map instrument-id to instrument instance of all instruments that are installed
 * in the environment. Using the instrument instance additional services can be
 * {@link #lookup(InstrumentInfo, Class) looked up} .
 *
 * @since 0.26
 */
@TruffleBoundary
public Map<String, InstrumentInfo> getInstruments() {
  return AccessAPI.engineAccess().getInstruments(vmObject);
}
origin: org.graalvm.truffle/truffle-api

/**
 * Returns {@code true} if the argument is a host symbol, representing the constructor and
 * static members of a Java class, as obtained by e.g. {@link #lookupHostSymbol}.
 *
 * @see #lookupHostSymbol(String)
 * @since 1.0
 */
@SuppressWarnings("static-method")
public boolean isHostSymbol(Object guestObject) {
  return AccessAPI.engineAccess().isHostSymbol(guestObject);
}
origin: com.oracle.truffle/truffle-api

/**
 * Returns <code>true</code> if host access is generally allowed. If this method returns
 * <code>false</code> then {@link #lookupHostSymbol(String)} will always fail.
 *
 * @since 0.27
 */
@TruffleBoundary
public boolean isHostLookupAllowed() {
  return AccessAPI.engineAccess().isHostAccessAllowed(vmObject, this);
}
origin: org.graalvm.truffle/truffle-api

/**
 * Get a parent context of this context, if any. This provides the hierarchy of inner contexts.
 *
 * @return a parent context, or <code>null</code> if there is no parent
 * @since 0.30
 */
@TruffleBoundary
public TruffleContext getParent() {
  return AccessAPI.engineAccess().getParentContext(impl);
}
origin: com.oracle.truffle/truffle-api

SourceSection findSourceLocation(Object obj) {
  Object c = getLanguageContext();
  if (c != UNSET_CONTEXT) {
    final Object rawValue = AccessAPI.engineAccess().findOriginalObject(obj);
    return spi.findSourceLocation(c, rawValue);
  } else {
    return null;
  }
}
com.oracle.truffle.apiTruffleLanguage$AccessAPIengineAccess

Popular methods of TruffleLanguage$AccessAPI

  • engineSupport
  • instrumentAccess
  • instrumentSupport
  • interopAccess
  • interopSupport
  • nodes
  • nodesAccess

Popular in Java

  • Finding current android device location
  • setContentView (Activity)
  • scheduleAtFixedRate (Timer)
  • setScale (BigDecimal)
  • BorderLayout (java.awt)
    A border layout lays out a container, arranging and resizing its components to fit in five regions:
  • FileNotFoundException (java.io)
    Thrown when a file specified by a program cannot be found.
  • SQLException (java.sql)
    An exception that indicates a failed JDBC operation. It provides the following information about pro
  • ExecutorService (java.util.concurrent)
    An Executor that provides methods to manage termination and methods that can produce a Future for tr
  • ImageIO (javax.imageio)
  • Servlet (javax.servlet)
    Defines methods that all servlets must implement. A servlet is a small Java program that runs within
  • Top plugins for WebStorm
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now