8141338: Move jdk.internal.dynalink package to jdk.dynalink
Reviewed-by: hannesw, sundar
This commit is contained in:
parent
c51be36580
commit
505e5097e6
@ -33,7 +33,7 @@ include JavaCompilation.gmk
|
|||||||
include SetupJavaCompilers.gmk
|
include SetupJavaCompilers.gmk
|
||||||
|
|
||||||
JDK_CLASSES := $(call PathList, $(strip $(addprefix $(JDK_OUTPUTDIR)/modules/, \
|
JDK_CLASSES := $(call PathList, $(strip $(addprefix $(JDK_OUTPUTDIR)/modules/, \
|
||||||
java.base java.logging java.scripting)))
|
java.base java.logging java.scripting jdk.dynalink)))
|
||||||
|
|
||||||
NASHORN_JAR := $(IMAGES_OUTPUTDIR)/nashorn.jar
|
NASHORN_JAR := $(IMAGES_OUTPUTDIR)/nashorn.jar
|
||||||
NASHORN_VERSION := $(JDK_VERSION)
|
NASHORN_VERSION := $(JDK_VERSION)
|
||||||
|
@ -52,6 +52,14 @@
|
|||||||
<available property="testng.already.present" file="${file.reference.testng.jar}"/>
|
<available property="testng.already.present" file="${file.reference.testng.jar}"/>
|
||||||
<antcall target="get-testng"/>
|
<antcall target="get-testng"/>
|
||||||
<available property="testng.available" file="${file.reference.testng.jar}"/>
|
<available property="testng.available" file="${file.reference.testng.jar}"/>
|
||||||
|
|
||||||
|
<!-- check if asmtools-6.0.jar is avaiable, and download it if it isn't -->
|
||||||
|
<!--
|
||||||
|
<available property="asmtools.already.present" file="${file.reference.asmtools.jar}"/>
|
||||||
|
<antcall target="get-asmtools"/>
|
||||||
|
<available property="asmtools.available" file="${file.reference.asmtools.jar}"/>
|
||||||
|
-->
|
||||||
|
|
||||||
<!-- check if Jemmy ang testng.jar are avaiable -->
|
<!-- check if Jemmy ang testng.jar are avaiable -->
|
||||||
<condition property="jemmy.jfx.testng.available" value="true">
|
<condition property="jemmy.jfx.testng.available" value="true">
|
||||||
<and>
|
<and>
|
||||||
@ -155,7 +163,7 @@
|
|||||||
<copy todir="${build.classes.dir}/jdk/nashorn/tools/resources">
|
<copy todir="${build.classes.dir}/jdk/nashorn/tools/resources">
|
||||||
<fileset dir="${nashorn.module.src.dir}/jdk/nashorn/tools/resources/"/>
|
<fileset dir="${nashorn.module.src.dir}/jdk/nashorn/tools/resources/"/>
|
||||||
</copy>
|
</copy>
|
||||||
<copy file="${nashorn.module.src.dir}/jdk/internal/dynalink/support/messages.properties" todir="${build.classes.dir}/jdk/internal/dynalink/support"/>
|
<copy file="${dynalink.module.src.dir}/jdk/dynalink/support/messages.properties" todir="${build.classes.dir}/jdk/dynalink/support"/>
|
||||||
<copy file="${nashorn.module.src.dir}/jdk/nashorn/internal/codegen/anchor.properties" todir="${build.classes.dir}/jdk/nashorn/internal/codegen"/>
|
<copy file="${nashorn.module.src.dir}/jdk/nashorn/internal/codegen/anchor.properties" todir="${build.classes.dir}/jdk/nashorn/internal/codegen"/>
|
||||||
|
|
||||||
<echo message="full=${nashorn.fullversion}" file="${build.classes.dir}/jdk/nashorn/internal/runtime/resources/version.properties"/>
|
<echo message="full=${nashorn.fullversion}" file="${build.classes.dir}/jdk/nashorn/internal/runtime/resources/version.properties"/>
|
||||||
@ -244,6 +252,7 @@
|
|||||||
<classpath>
|
<classpath>
|
||||||
<pathelement location="${build.classes.dir}"/>
|
<pathelement location="${build.classes.dir}"/>
|
||||||
</classpath>
|
</classpath>
|
||||||
|
<fileset dir="${dynalink.module.src.dir}" includes="**/*.java"/>
|
||||||
<fileset dir="${nashorn.module.src.dir}" includes="**/*.java"/>
|
<fileset dir="${nashorn.module.src.dir}" includes="**/*.java"/>
|
||||||
<fileset dir="${nashorn.shell.module.src.dir}" includes="**/*.java"/>
|
<fileset dir="${nashorn.shell.module.src.dir}" includes="**/*.java"/>
|
||||||
<link href="http://docs.oracle.com/javase/8/docs/api/"/>
|
<link href="http://docs.oracle.com/javase/8/docs/api/"/>
|
||||||
@ -263,6 +272,18 @@
|
|||||||
</javadoc>
|
</javadoc>
|
||||||
</target>
|
</target>
|
||||||
|
|
||||||
|
<!-- generate javadoc only for Dynalink API classes -->
|
||||||
|
<target name="dynalinkapi" depends="jar">
|
||||||
|
<javadoc destdir="${dist.javadoc.dir}" use="yes"
|
||||||
|
windowtitle="Dynalink"
|
||||||
|
additionalparam="-quiet" failonerror="true" useexternalfile="true">
|
||||||
|
<classpath>
|
||||||
|
<pathelement location="${build.classes.dir}"/>
|
||||||
|
</classpath>
|
||||||
|
<fileset dir="${dynalink.module.src.dir}" includes="**/*.java" excludes="jdk/dynalink/internal/*.java"/>
|
||||||
|
<link href="http://docs.oracle.com/javase/8/docs/api/"/>
|
||||||
|
</javadoc>
|
||||||
|
</target>
|
||||||
|
|
||||||
<!-- generate shell.html for shell tool documentation -->
|
<!-- generate shell.html for shell tool documentation -->
|
||||||
<target name="shelldoc" depends="jar">
|
<target name="shelldoc" depends="jar">
|
||||||
@ -321,14 +342,20 @@
|
|||||||
|
|
||||||
<!-- tests that check nashorn internals and internal API -->
|
<!-- tests that check nashorn internals and internal API -->
|
||||||
<jar jarfile="${nashorn.internal.tests.jar}">
|
<jar jarfile="${nashorn.internal.tests.jar}">
|
||||||
<fileset dir="${build.test.classes.dir}" excludes="**/api/**"/>
|
<fileset dir="${build.test.classes.dir}" includes="**/internal/**"/>
|
||||||
|
<fileset dir="${build.test.classes.dir}" includes="**/test/tools/**"/>
|
||||||
|
<fileset dir="${build.test.classes.dir}" includes="**/models/**"/>
|
||||||
|
<fileset dir="${build.test.classes.dir}" includes="**/jdk/dynalink/test/Trusted**"/>
|
||||||
|
<fileset dir="${build.test.classes.dir}" includes="**/META-INF/**"/>
|
||||||
</jar>
|
</jar>
|
||||||
|
|
||||||
<!-- tests that check nashorn script engine (jsr-223) API -->
|
<!-- tests that check nashorn script engine (jsr-223) API and dynalink API -->
|
||||||
<jar jarfile="${nashorn.api.tests.jar}">
|
<jar jarfile="${nashorn.api.tests.jar}">
|
||||||
|
<fileset dir="${build.test.classes.dir}" includes="**/jdk/dynalink/**" excludes="**/jdk/dynalink/test/Trusted**"/>
|
||||||
<fileset dir="${build.test.classes.dir}" includes="**/api/**"/>
|
<fileset dir="${build.test.classes.dir}" includes="**/api/**"/>
|
||||||
<fileset dir="${build.test.classes.dir}" includes="**/META-INF/**"/>
|
<fileset dir="${build.test.classes.dir}" includes="**/META-INF/**"/>
|
||||||
<fileset dir="${build.test.classes.dir}" includes="**/resources/*.js"/>
|
<fileset dir="${build.test.classes.dir}" includes="**/resources/*.js"/>
|
||||||
|
<fileset dir="${build.test.classes.dir}" includes="**/UnnamedPackage**"/>
|
||||||
</jar>
|
</jar>
|
||||||
|
|
||||||
</target>
|
</target>
|
||||||
@ -432,6 +459,8 @@ grant codeBase "file:/${basedir}/test/script/markdown.js" {
|
|||||||
<!-- only to be invoked as dependency of "test" target -->
|
<!-- only to be invoked as dependency of "test" target -->
|
||||||
<target name="-test-classes-all" depends="jar" unless="test.class">
|
<target name="-test-classes-all" depends="jar" unless="test.class">
|
||||||
<fileset id="test.classes" dir="${build.test.classes.dir}">
|
<fileset id="test.classes" dir="${build.test.classes.dir}">
|
||||||
|
<include name="**/dynalink/test/*Test.class"/>
|
||||||
|
<include name="**/dynalink/beans/test/*Test.class"/>
|
||||||
<include name="**/api/javaaccess/test/*Test.class"/>
|
<include name="**/api/javaaccess/test/*Test.class"/>
|
||||||
<include name="**/api/scripting/test/*Test.class"/>
|
<include name="**/api/scripting/test/*Test.class"/>
|
||||||
<include name="**/api/tree/test/*Test.class"/>
|
<include name="**/api/tree/test/*Test.class"/>
|
||||||
@ -773,6 +802,20 @@ grant codeBase "file:/${basedir}/test/script/markdown.js" {
|
|||||||
<delete dir="${test.lib}${file.separator}testng-6.8"/>
|
<delete dir="${test.lib}${file.separator}testng-6.8"/>
|
||||||
</target>
|
</target>
|
||||||
|
|
||||||
|
<!-- download and install asmtools.jar -->
|
||||||
|
<target name="get-asmtools" unless="asmtools.already.present">
|
||||||
|
<get src="https://adopt-openjdk.ci.cloudbees.com/view/OpenJDK/job/asmtools/lastSuccessfulBuild/artifact/asmtools-6.0.tar.gz" dest="${test.lib}" skipexisting="true" ignoreerrors="true"/>
|
||||||
|
<untar src="${test.lib}${file.separator}asmtools-6.0.tar.gz" dest="${test.lib}" compression="gzip"/>
|
||||||
|
<!-- they are tar.gz'ing a .zip file! -->
|
||||||
|
<unzip src="${test.lib}${file.separator}asmtools-6.0.zip" dest="${test.lib}">
|
||||||
|
<patternset>
|
||||||
|
<include name="asmtools-6.0/lib/asmtools.jar"/>
|
||||||
|
</patternset>
|
||||||
|
</unzip>
|
||||||
|
<move file="${test.lib}${file.separator}asmtools-6.0${file.separator}lib${file.separator}asmtools.jar" tofile="${test.lib}${file.separator}asmtools.jar"/>
|
||||||
|
<delete dir="${test.lib}${file.separator}asmtools-6.0"/>
|
||||||
|
</target>
|
||||||
|
|
||||||
<!-- run all tests -->
|
<!-- run all tests -->
|
||||||
<target name="alltests" depends="externals, update-externals, test, test262parallel, testmarkdown, perf"/>
|
<target name="alltests" depends="externals, update-externals, test, test262parallel, testmarkdown, perf"/>
|
||||||
|
|
||||||
|
@ -49,6 +49,10 @@
|
|||||||
<label>../src/jdk.scripting.nashorn/share/classes</label>
|
<label>../src/jdk.scripting.nashorn/share/classes</label>
|
||||||
<location>../src/jdk.scripting.nashorn/share/classes</location>
|
<location>../src/jdk.scripting.nashorn/share/classes</location>
|
||||||
</source-folder>
|
</source-folder>
|
||||||
|
<source-folder>
|
||||||
|
<label>../src/jdk.scripting.nashorn.shell/share/classes</label>
|
||||||
|
<location>../src/jdk.scripting.nashorn.shell/share/classes</location>
|
||||||
|
</source-folder>
|
||||||
<source-folder>
|
<source-folder>
|
||||||
<label>../test/src</label>
|
<label>../test/src</label>
|
||||||
<type>java</type>
|
<type>java</type>
|
||||||
@ -74,8 +78,14 @@
|
|||||||
<encoding>UTF-8</encoding>
|
<encoding>UTF-8</encoding>
|
||||||
</source-folder>
|
</source-folder>
|
||||||
<source-folder>
|
<source-folder>
|
||||||
<label>../src/jdk.scripting.nashorn.shell/share/classes</label>
|
<label>../src/jdk.dynalink/share/classes</label>
|
||||||
<location>../src/jdk.scripting.nashorn.shell/share/classes</location>
|
<type>java</type>
|
||||||
|
<location>../src/jdk.dynalink/share/classes</location>
|
||||||
|
<encoding>UTF-8</encoding>
|
||||||
|
</source-folder>
|
||||||
|
<source-folder>
|
||||||
|
<label>../src/jdk.dynalink/share/classes</label>
|
||||||
|
<location>../src/jdk.dynalink/share/classes</location>
|
||||||
</source-folder>
|
</source-folder>
|
||||||
</folders>
|
</folders>
|
||||||
<ide-actions>
|
<ide-actions>
|
||||||
@ -153,6 +163,10 @@
|
|||||||
<label>../src/jdk.scripting.nashorn.shell/share/classes</label>
|
<label>../src/jdk.scripting.nashorn.shell/share/classes</label>
|
||||||
<location>../src/jdk.scripting.nashorn.shell/share/classes</location>
|
<location>../src/jdk.scripting.nashorn.shell/share/classes</location>
|
||||||
</source-folder>
|
</source-folder>
|
||||||
|
<source-folder style="packages">
|
||||||
|
<label>../src/jdk.dynalink/share/classes</label>
|
||||||
|
<location>../src/jdk.dynalink/share/classes</location>
|
||||||
|
</source-folder>
|
||||||
<source-file>
|
<source-file>
|
||||||
<location>build.xml</location>
|
<location>build.xml</location>
|
||||||
</source-file>
|
</source-file>
|
||||||
@ -189,6 +203,10 @@
|
|||||||
<package-root>../src/jdk.scripting.nashorn.shell/share/classes</package-root>
|
<package-root>../src/jdk.scripting.nashorn.shell/share/classes</package-root>
|
||||||
<source-level>1.8</source-level>
|
<source-level>1.8</source-level>
|
||||||
</compilation-unit>
|
</compilation-unit>
|
||||||
|
<compilation-unit>
|
||||||
|
<package-root>../src/jdk.dynalink/share/classes</package-root>
|
||||||
|
<source-level>1.8</source-level>
|
||||||
|
</compilation-unit>
|
||||||
</java-data>
|
</java-data>
|
||||||
</configuration>
|
</configuration>
|
||||||
</project>
|
</project>
|
||||||
|
@ -85,6 +85,7 @@ test.lib=${basedir}${file.separator}test${file.separator}lib
|
|||||||
|
|
||||||
# jars refererred
|
# jars refererred
|
||||||
file.reference.testng.jar=${test.lib}${file.separator}testng.jar
|
file.reference.testng.jar=${test.lib}${file.separator}testng.jar
|
||||||
|
file.reference.asmtools.jar=${test.lib}${file.separator}asmtools-60.jar
|
||||||
|
|
||||||
# Set testng verbose level
|
# Set testng verbose level
|
||||||
# From TestNG docs: "the verbosity level (0 to 10 where 10 is most detailed)
|
# From TestNG docs: "the verbosity level (0 to 10 where 10 is most detailed)
|
||||||
@ -269,10 +270,12 @@ run.test.classpath=\
|
|||||||
${nashorn.internal.tests.jar}${path.separator}\
|
${nashorn.internal.tests.jar}${path.separator}\
|
||||||
${nashorn.api.tests.jar}
|
${nashorn.api.tests.jar}
|
||||||
|
|
||||||
|
dynalink.module.src.dir=src/jdk.dynalink/share/classes
|
||||||
nashorn.module.src.dir=src/jdk.scripting.nashorn/share/classes
|
nashorn.module.src.dir=src/jdk.scripting.nashorn/share/classes
|
||||||
nashorn.shell.module.src.dir=src/jdk.scripting.nashorn.shell/share/classes
|
nashorn.shell.module.src.dir=src/jdk.scripting.nashorn.shell/share/classes
|
||||||
|
|
||||||
src.dir=${nashorn.module.src.dir}${path.separator}\
|
src.dir=${dynalink.module.src.dir}${path.separator}\
|
||||||
|
${nashorn.module.src.dir}${path.separator}\
|
||||||
${nashorn.shell.module.src.dir}${path.separator}\
|
${nashorn.shell.module.src.dir}${path.separator}\
|
||||||
${jdk.jline.src.dir}
|
${jdk.jline.src.dir}
|
||||||
|
|
||||||
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink;
|
package jdk.dynalink;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.lang.invoke.MethodHandles.Lookup;
|
import java.lang.invoke.MethodHandles.Lookup;
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink;
|
package jdk.dynalink;
|
||||||
|
|
||||||
import java.lang.ref.Reference;
|
import java.lang.ref.Reference;
|
||||||
import java.lang.ref.SoftReference;
|
import java.lang.ref.SoftReference;
|
||||||
@ -92,8 +92,8 @@ import java.util.Map;
|
|||||||
import java.util.WeakHashMap;
|
import java.util.WeakHashMap;
|
||||||
import java.util.concurrent.ConcurrentHashMap;
|
import java.util.concurrent.ConcurrentHashMap;
|
||||||
import java.util.concurrent.ConcurrentMap;
|
import java.util.concurrent.ConcurrentMap;
|
||||||
import jdk.internal.dynalink.internal.AccessControlContextFactory;
|
import jdk.dynalink.internal.AccessControlContextFactory;
|
||||||
import jdk.internal.dynalink.internal.InternalTypeUtilities;
|
import jdk.dynalink.internal.InternalTypeUtilities;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A dual map that can either strongly or weakly reference a given class depending on whether the class is visible from
|
* A dual map that can either strongly or weakly reference a given class depending on whether the class is visible from
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink;
|
package jdk.dynalink;
|
||||||
|
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
@ -81,22 +81,22 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink;
|
package jdk.dynalink;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import java.lang.invoke.MutableCallSite;
|
import java.lang.invoke.MutableCallSite;
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocationTransformer;
|
import jdk.dynalink.linker.GuardedInvocationTransformer;
|
||||||
import jdk.internal.dynalink.linker.GuardingDynamicLinker;
|
import jdk.dynalink.linker.GuardingDynamicLinker;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
import jdk.internal.dynalink.linker.support.Lookup;
|
import jdk.dynalink.linker.support.Lookup;
|
||||||
import jdk.internal.dynalink.linker.support.SimpleLinkRequest;
|
import jdk.dynalink.linker.support.SimpleLinkRequest;
|
||||||
import jdk.internal.dynalink.support.ChainedCallSite;
|
import jdk.dynalink.support.ChainedCallSite;
|
||||||
import jdk.internal.dynalink.support.SimpleRelinkableCallSite;
|
import jdk.dynalink.support.SimpleRelinkableCallSite;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The linker for {@link RelinkableCallSite} objects. A dynamic linker is a main
|
* The linker for {@link RelinkableCallSite} objects. A dynamic linker is a main
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink;
|
package jdk.dynalink;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
@ -101,21 +101,21 @@ import java.util.ServiceConfigurationError;
|
|||||||
import java.util.ServiceLoader;
|
import java.util.ServiceLoader;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
import jdk.internal.dynalink.beans.BeansLinker;
|
import jdk.dynalink.beans.BeansLinker;
|
||||||
import jdk.internal.dynalink.internal.AccessControlContextFactory;
|
import jdk.dynalink.internal.AccessControlContextFactory;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocationTransformer;
|
import jdk.dynalink.linker.GuardedInvocationTransformer;
|
||||||
import jdk.internal.dynalink.linker.GuardingDynamicLinker;
|
import jdk.dynalink.linker.GuardingDynamicLinker;
|
||||||
import jdk.internal.dynalink.linker.GuardingDynamicLinkerExporter;
|
import jdk.dynalink.linker.GuardingDynamicLinkerExporter;
|
||||||
import jdk.internal.dynalink.linker.GuardingTypeConverterFactory;
|
import jdk.dynalink.linker.GuardingTypeConverterFactory;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
import jdk.internal.dynalink.linker.MethodHandleTransformer;
|
import jdk.dynalink.linker.MethodHandleTransformer;
|
||||||
import jdk.internal.dynalink.linker.MethodTypeConversionStrategy;
|
import jdk.dynalink.linker.MethodTypeConversionStrategy;
|
||||||
import jdk.internal.dynalink.linker.support.CompositeGuardingDynamicLinker;
|
import jdk.dynalink.linker.support.CompositeGuardingDynamicLinker;
|
||||||
import jdk.internal.dynalink.linker.support.CompositeTypeBasedGuardingDynamicLinker;
|
import jdk.dynalink.linker.support.CompositeTypeBasedGuardingDynamicLinker;
|
||||||
import jdk.internal.dynalink.linker.support.DefaultInternalObjectFilter;
|
import jdk.dynalink.linker.support.DefaultInternalObjectFilter;
|
||||||
import jdk.internal.dynalink.linker.support.TypeUtilities;
|
import jdk.dynalink.linker.support.TypeUtilities;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A factory class for creating {@link DynamicLinker} objects. Dynamic linkers
|
* A factory class for creating {@link DynamicLinker} objects. Dynamic linkers
|
@ -81,17 +81,17 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink;
|
package jdk.dynalink;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import jdk.internal.dynalink.linker.ConversionComparator.Comparison;
|
import jdk.dynalink.linker.ConversionComparator.Comparison;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.GuardingDynamicLinker;
|
import jdk.dynalink.linker.GuardingDynamicLinker;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
import jdk.internal.dynalink.linker.MethodHandleTransformer;
|
import jdk.dynalink.linker.MethodHandleTransformer;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Default implementation of the {@link LinkerServices} interface.
|
* Default implementation of the {@link LinkerServices} interface.
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink;
|
package jdk.dynalink;
|
||||||
|
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
|
@ -81,9 +81,9 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink;
|
package jdk.dynalink;
|
||||||
|
|
||||||
import jdk.internal.dynalink.linker.GuardingDynamicLinker;
|
import jdk.dynalink.linker.GuardingDynamicLinker;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Thrown at the invocation if the call site can not be linked by any available {@link GuardingDynamicLinker}.
|
* Thrown at the invocation if the call site can not be linked by any available {@link GuardingDynamicLinker}.
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink;
|
package jdk.dynalink;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* An object that describes a dynamic operation. Dynalink defines a set of
|
* An object that describes a dynamic operation. Dynalink defines a set of
|
@ -81,13 +81,13 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink;
|
package jdk.dynalink;
|
||||||
|
|
||||||
import java.lang.invoke.CallSite;
|
import java.lang.invoke.CallSite;
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.support.ChainedCallSite;
|
import jdk.dynalink.support.ChainedCallSite;
|
||||||
import jdk.internal.dynalink.support.SimpleRelinkableCallSite;
|
import jdk.dynalink.support.SimpleRelinkableCallSite;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Interface for call sites managed by a {@link DynamicLinker}. Users of
|
* Interface for call sites managed by a {@link DynamicLinker}. Users of
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink;
|
package jdk.dynalink;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Defines the standard dynamic operations. Getter and setter operations defined
|
* Defines the standard dynamic operations. Getter and setter operations defined
|
||||||
@ -127,7 +127,7 @@ public enum StandardOperation implements Operation {
|
|||||||
*/
|
*/
|
||||||
SET_ELEMENT,
|
SET_ELEMENT,
|
||||||
/**
|
/**
|
||||||
* Get the length of an array of size of a collection. Call sites with
|
* Get the length of an array or size of a collection. Call sites with
|
||||||
* this operation should have a signature of <tt>(receiver)→value</tt>,
|
* this operation should have a signature of <tt>(receiver)→value</tt>,
|
||||||
* with all parameters and return type being of any type (either primitive
|
* with all parameters and return type being of any type (either primitive
|
||||||
* or reference).
|
* or reference).
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink;
|
package jdk.dynalink;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
@ -94,14 +94,14 @@ import java.security.PrivilegedAction;
|
|||||||
import java.util.LinkedList;
|
import java.util.LinkedList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
import jdk.internal.dynalink.internal.AccessControlContextFactory;
|
import jdk.dynalink.internal.AccessControlContextFactory;
|
||||||
import jdk.internal.dynalink.linker.ConversionComparator;
|
import jdk.dynalink.linker.ConversionComparator;
|
||||||
import jdk.internal.dynalink.linker.ConversionComparator.Comparison;
|
import jdk.dynalink.linker.ConversionComparator.Comparison;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.GuardingTypeConverterFactory;
|
import jdk.dynalink.linker.GuardingTypeConverterFactory;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
import jdk.internal.dynalink.linker.MethodTypeConversionStrategy;
|
import jdk.dynalink.linker.MethodTypeConversionStrategy;
|
||||||
import jdk.internal.dynalink.linker.support.TypeUtilities;
|
import jdk.dynalink.linker.support.TypeUtilities;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A factory for type converters. This class is the main implementation behind the
|
* A factory for type converters. This class is the main implementation behind the
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
@ -98,19 +98,19 @@ import java.util.HashMap;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.CompositeOperation;
|
import jdk.dynalink.CompositeOperation;
|
||||||
import jdk.internal.dynalink.NamedOperation;
|
import jdk.dynalink.NamedOperation;
|
||||||
import jdk.internal.dynalink.Operation;
|
import jdk.dynalink.Operation;
|
||||||
import jdk.internal.dynalink.StandardOperation;
|
import jdk.dynalink.StandardOperation;
|
||||||
import jdk.internal.dynalink.beans.GuardedInvocationComponent.ValidationType;
|
import jdk.dynalink.beans.GuardedInvocationComponent.ValidationType;
|
||||||
import jdk.internal.dynalink.internal.InternalTypeUtilities;
|
import jdk.dynalink.internal.InternalTypeUtilities;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.GuardingDynamicLinker;
|
import jdk.dynalink.linker.GuardingDynamicLinker;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
import jdk.internal.dynalink.linker.support.Guards;
|
import jdk.dynalink.linker.support.Guards;
|
||||||
import jdk.internal.dynalink.linker.support.Lookup;
|
import jdk.dynalink.linker.support.Lookup;
|
||||||
import sun.reflect.CallerSensitive;
|
import sun.reflect.CallerSensitive;
|
||||||
|
|
||||||
/**
|
/**
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.reflect.Method;
|
import java.lang.reflect.Method;
|
||||||
import java.lang.reflect.Modifier;
|
import java.lang.reflect.Modifier;
|
@ -81,12 +81,12 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import java.util.LinkedList;
|
import java.util.LinkedList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import jdk.internal.dynalink.linker.support.TypeUtilities;
|
import jdk.dynalink.linker.support.TypeUtilities;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents overloaded methods applicable to a specific call site signature.
|
* Represents overloaded methods applicable to a specific call site signature.
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
@ -90,16 +90,16 @@ import java.lang.reflect.Array;
|
|||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.Operation;
|
import jdk.dynalink.Operation;
|
||||||
import jdk.internal.dynalink.StandardOperation;
|
import jdk.dynalink.StandardOperation;
|
||||||
import jdk.internal.dynalink.beans.GuardedInvocationComponent.ValidationType;
|
import jdk.dynalink.beans.GuardedInvocationComponent.ValidationType;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
import jdk.internal.dynalink.linker.TypeBasedGuardingDynamicLinker;
|
import jdk.dynalink.linker.TypeBasedGuardingDynamicLinker;
|
||||||
import jdk.internal.dynalink.linker.support.Guards;
|
import jdk.dynalink.linker.support.Guards;
|
||||||
import jdk.internal.dynalink.linker.support.Lookup;
|
import jdk.dynalink.linker.support.Lookup;
|
||||||
import jdk.internal.dynalink.linker.support.TypeUtilities;
|
import jdk.dynalink.linker.support.TypeUtilities;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A class that provides linking capabilities for a single POJO class. Normally not used directly, but managed by
|
* A class that provides linking capabilities for a single POJO class. Normally not used directly, but managed by
|
@ -81,18 +81,18 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandles.Lookup;
|
import java.lang.invoke.MethodHandles.Lookup;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
import jdk.internal.dynalink.DynamicLinkerFactory;
|
import jdk.dynalink.DynamicLinkerFactory;
|
||||||
import jdk.internal.dynalink.StandardOperation;
|
import jdk.dynalink.StandardOperation;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.GuardingDynamicLinker;
|
import jdk.dynalink.linker.GuardingDynamicLinker;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
import jdk.internal.dynalink.linker.TypeBasedGuardingDynamicLinker;
|
import jdk.dynalink.linker.TypeBasedGuardingDynamicLinker;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A linker for ordinary Java objects. Normally used as the ultimate fallback
|
* A linker for ordinary Java objects. Normally used as the ultimate fallback
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
@ -94,9 +94,9 @@ import java.lang.reflect.Modifier;
|
|||||||
import java.security.AccessControlContext;
|
import java.security.AccessControlContext;
|
||||||
import java.security.AccessController;
|
import java.security.AccessController;
|
||||||
import java.security.PrivilegedAction;
|
import java.security.PrivilegedAction;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.internal.AccessControlContextFactory;
|
import jdk.dynalink.internal.AccessControlContextFactory;
|
||||||
import jdk.internal.dynalink.linker.support.Lookup;
|
import jdk.dynalink.linker.support.Lookup;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A dynamic method bound to exactly one Java method or constructor that is caller sensitive. Since the target method is
|
* A dynamic method bound to exactly one Java method or constructor that is caller sensitive. Since the target method is
|
@ -81,13 +81,13 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.reflect.Modifier;
|
import java.lang.reflect.Modifier;
|
||||||
import java.security.AccessControlContext;
|
import java.security.AccessControlContext;
|
||||||
import java.security.AccessController;
|
import java.security.AccessController;
|
||||||
import java.security.PrivilegedAction;
|
import java.security.PrivilegedAction;
|
||||||
import jdk.internal.dynalink.internal.AccessControlContextFactory;
|
import jdk.dynalink.internal.AccessControlContextFactory;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A utility class to check whether a given class is in a package with restricted access e.g. "sun.*" etc.
|
* A utility class to check whether a given class is in a package with restricted access e.g. "sun.*" etc.
|
@ -81,13 +81,13 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import jdk.internal.dynalink.beans.GuardedInvocationComponent.ValidationType;
|
import jdk.dynalink.beans.GuardedInvocationComponent.ValidationType;
|
||||||
import jdk.internal.dynalink.linker.support.Lookup;
|
import jdk.dynalink.linker.support.Lookup;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A linker for java.lang.Class objects. Provides a synthetic property "static" that allows access to static fields and
|
* A linker for java.lang.Class objects. Provides a synthetic property "static" that allows access to static fields and
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
@ -90,10 +90,10 @@ import java.security.AccessController;
|
|||||||
import java.security.PrivilegedAction;
|
import java.security.PrivilegedAction;
|
||||||
import java.util.LinkedList;
|
import java.util.LinkedList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import jdk.internal.dynalink.internal.AccessControlContextFactory;
|
import jdk.dynalink.internal.AccessControlContextFactory;
|
||||||
import jdk.internal.dynalink.internal.InternalTypeUtilities;
|
import jdk.dynalink.internal.InternalTypeUtilities;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
import jdk.internal.dynalink.linker.support.TypeUtilities;
|
import jdk.dynalink.linker.support.TypeUtilities;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents a sequence of {@link Class} objects, useful for representing method signatures. Provides value
|
* Represents a sequence of {@link Class} objects, useful for representing method signatures. Provides value
|
@ -81,11 +81,11 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents a single dynamic method. A "dynamic" method can be bound to a single Java method, or can be bound to all
|
* Represents a single dynamic method. A "dynamic" method can be bound to a single Java method, or can be bound to all
|
@ -81,19 +81,19 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.NamedOperation;
|
import jdk.dynalink.NamedOperation;
|
||||||
import jdk.internal.dynalink.Operation;
|
import jdk.dynalink.Operation;
|
||||||
import jdk.internal.dynalink.StandardOperation;
|
import jdk.dynalink.StandardOperation;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
import jdk.internal.dynalink.linker.TypeBasedGuardingDynamicLinker;
|
import jdk.dynalink.linker.TypeBasedGuardingDynamicLinker;
|
||||||
import jdk.internal.dynalink.linker.support.Guards;
|
import jdk.dynalink.linker.support.Guards;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Simple linker that implements the {@link StandardOperation#CALL} operation
|
* Simple linker that implements the {@link StandardOperation#CALL} operation
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.reflect.Field;
|
import java.lang.reflect.Field;
|
||||||
@ -92,7 +92,7 @@ import java.util.ArrayList;
|
|||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import jdk.internal.dynalink.linker.support.Lookup;
|
import jdk.dynalink.linker.support.Lookup;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Base for classes that expose class field and method information to an {@link AbstractJavaLinker}. There are
|
* Base for classes that expose class field and method information to an {@link AbstractJavaLinker}. There are
|
@ -81,10 +81,10 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents one component for a GuardedInvocation of a potentially composite operation of an
|
* Represents one component for a GuardedInvocation of a potentially composite operation of an
|
@ -81,16 +81,16 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
||||||
import java.util.LinkedList;
|
import java.util.LinkedList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import jdk.internal.dynalink.linker.ConversionComparator.Comparison;
|
import jdk.dynalink.linker.ConversionComparator.Comparison;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
import jdk.internal.dynalink.linker.support.TypeUtilities;
|
import jdk.dynalink.linker.support.TypeUtilities;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Utility class that encapsulates the algorithm for choosing the maximally specific methods.
|
* Utility class that encapsulates the algorithm for choosing the maximally specific methods.
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
@ -97,11 +97,11 @@ import java.util.LinkedList;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.beans.ApplicableOverloadedMethods.ApplicabilityTest;
|
import jdk.dynalink.beans.ApplicableOverloadedMethods.ApplicabilityTest;
|
||||||
import jdk.internal.dynalink.internal.AccessControlContextFactory;
|
import jdk.dynalink.internal.AccessControlContextFactory;
|
||||||
import jdk.internal.dynalink.internal.InternalTypeUtilities;
|
import jdk.dynalink.internal.InternalTypeUtilities;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents a group of {@link SingleDynamicMethod} objects that represents all overloads of a particular name (or all
|
* Represents a group of {@link SingleDynamicMethod} objects that represents all overloads of a particular name (or all
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
@ -91,9 +91,9 @@ import java.util.Iterator;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.concurrent.ConcurrentHashMap;
|
import java.util.concurrent.ConcurrentHashMap;
|
||||||
import jdk.internal.dynalink.internal.InternalTypeUtilities;
|
import jdk.dynalink.internal.InternalTypeUtilities;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
import jdk.internal.dynalink.linker.support.Lookup;
|
import jdk.dynalink.linker.support.Lookup;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents a subset of overloaded methods for a certain method name on a certain class. It can be either a fixarg or
|
* Represents a subset of overloaded methods for a certain method name on a certain class. It can be either a fixarg or
|
@ -81,11 +81,11 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A dynamic method bound to exactly one Java method or constructor that is not caller sensitive. Since its target is
|
* A dynamic method bound to exactly one Java method or constructor that is not caller sensitive. Since its target is
|
@ -81,17 +81,17 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import java.lang.reflect.Array;
|
import java.lang.reflect.Array;
|
||||||
import java.util.StringTokenizer;
|
import java.util.StringTokenizer;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
import jdk.internal.dynalink.linker.support.Guards;
|
import jdk.dynalink.linker.support.Guards;
|
||||||
import jdk.internal.dynalink.linker.support.Lookup;
|
import jdk.dynalink.linker.support.Lookup;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Base class for dynamic methods that dispatch to a single target Java method or constructor. Handles adaptation of the
|
* Base class for dynamic methods that dispatch to a single target Java method or constructor. Handles adaptation of the
|
@ -81,11 +81,11 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
import jdk.internal.dynalink.StandardOperation;
|
import jdk.dynalink.StandardOperation;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Object that allows access to the static members of a class (its static
|
* Object that allows access to the static members of a class (its static
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
@ -89,15 +89,15 @@ import java.lang.invoke.MethodType;
|
|||||||
import java.lang.reflect.Array;
|
import java.lang.reflect.Array;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.NamedOperation;
|
import jdk.dynalink.NamedOperation;
|
||||||
import jdk.internal.dynalink.StandardOperation;
|
import jdk.dynalink.StandardOperation;
|
||||||
import jdk.internal.dynalink.beans.GuardedInvocationComponent.ValidationType;
|
import jdk.dynalink.beans.GuardedInvocationComponent.ValidationType;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
import jdk.internal.dynalink.linker.TypeBasedGuardingDynamicLinker;
|
import jdk.dynalink.linker.TypeBasedGuardingDynamicLinker;
|
||||||
import jdk.internal.dynalink.linker.support.Lookup;
|
import jdk.dynalink.linker.support.Lookup;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Provides a linker for the {@link StaticClass} objects.
|
* Provides a linker for the {@link StaticClass} objects.
|
@ -86,4 +86,4 @@
|
|||||||
* @since 1.9
|
* @since 1.9
|
||||||
*/
|
*/
|
||||||
@jdk.Exported
|
@jdk.Exported
|
||||||
package jdk.internal.dynalink.beans;
|
package jdk.dynalink.beans;
|
@ -23,7 +23,7 @@
|
|||||||
* questions.
|
* questions.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.internal;
|
package jdk.dynalink.internal;
|
||||||
|
|
||||||
import java.security.AccessControlContext;
|
import java.security.AccessControlContext;
|
||||||
import java.security.Permission;
|
import java.security.Permission;
|
@ -22,14 +22,14 @@
|
|||||||
* or visit www.oracle.com if you need additional information or have any
|
* or visit www.oracle.com if you need additional information or have any
|
||||||
* questions.
|
* questions.
|
||||||
*/
|
*/
|
||||||
package jdk.internal.dynalink.internal;
|
package jdk.dynalink.internal;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.HashSet;
|
import java.util.HashSet;
|
||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
import jdk.internal.dynalink.linker.support.TypeUtilities;
|
import jdk.dynalink.linker.support.TypeUtilities;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Various static utility methods for testing type relationships; internal to Dynalink.
|
* Various static utility methods for testing type relationships; internal to Dynalink.
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker;
|
package jdk.dynalink.linker;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker;
|
package jdk.dynalink.linker;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
@ -90,8 +90,8 @@ import java.lang.invoke.SwitchPoint;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.linker.support.Guards;
|
import jdk.dynalink.linker.support.Guards;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents a conditionally valid method handle. Usually produced as a return
|
* Represents a conditionally valid method handle. Usually produced as a return
|
@ -81,9 +81,9 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker;
|
package jdk.dynalink.linker;
|
||||||
|
|
||||||
import jdk.internal.dynalink.DynamicLinkerFactory;
|
import jdk.dynalink.DynamicLinkerFactory;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Interface for objects that are used to transform one guarded invocation into
|
* Interface for objects that are used to transform one guarded invocation into
|
@ -81,12 +81,12 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker;
|
package jdk.dynalink.linker;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import jdk.internal.dynalink.DynamicLinkerFactory;
|
import jdk.dynalink.DynamicLinkerFactory;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The base interface for language-specific dynamic linkers. Such linkers
|
* The base interface for language-specific dynamic linkers. Such linkers
|
@ -23,13 +23,13 @@
|
|||||||
* questions.
|
* questions.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker;
|
package jdk.dynalink.linker;
|
||||||
|
|
||||||
import java.security.Permission;
|
import java.security.Permission;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.ServiceLoader;
|
import java.util.ServiceLoader;
|
||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
import jdk.internal.dynalink.DynamicLinkerFactory;
|
import jdk.dynalink.DynamicLinkerFactory;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A class acting as a supplier of guarding dynamic linkers that can be
|
* A class acting as a supplier of guarding dynamic linkers that can be
|
||||||
@ -37,7 +37,7 @@ import jdk.internal.dynalink.DynamicLinkerFactory;
|
|||||||
* to export their own linkers should subclass this class and implement the
|
* to export their own linkers should subclass this class and implement the
|
||||||
* {@link #get()} method to return a list of exported linkers and declare the
|
* {@link #get()} method to return a list of exported linkers and declare the
|
||||||
* subclass in
|
* subclass in
|
||||||
* {@code /META-INF/services/jdk.internal.dynalink.linker.GuardingDynamicLinkerExporter}
|
* {@code /META-INF/services/jdk.dynalink.linker.GuardingDynamicLinkerExporter}
|
||||||
* resource of their distribution (typically, JAR file) so that dynamic linker
|
* resource of their distribution (typically, JAR file) so that dynamic linker
|
||||||
* factories can discover them using the {@link ServiceLoader} mechanism. Note
|
* factories can discover them using the {@link ServiceLoader} mechanism. Note
|
||||||
* that instantiating this class is tied to a security check for the
|
* that instantiating this class is tied to a security check for the
|
@ -81,13 +81,13 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker;
|
package jdk.dynalink.linker;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.beans.BeansLinker;
|
import jdk.dynalink.beans.BeansLinker;
|
||||||
import jdk.internal.dynalink.linker.support.TypeUtilities;
|
import jdk.dynalink.linker.support.TypeUtilities;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Optional interface that can be implemented by {@link GuardingDynamicLinker}
|
* Optional interface that can be implemented by {@link GuardingDynamicLinker}
|
@ -81,11 +81,11 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker;
|
package jdk.dynalink.linker;
|
||||||
|
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.DynamicLinker;
|
import jdk.dynalink.DynamicLinker;
|
||||||
import jdk.internal.dynalink.DynamicLinkerFactory;
|
import jdk.dynalink.DynamicLinkerFactory;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents a request to link a particular invocation at a particular call
|
* Represents a request to link a particular invocation at a particular call
|
@ -81,15 +81,15 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker;
|
package jdk.dynalink.linker;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import jdk.internal.dynalink.DynamicLinker;
|
import jdk.dynalink.DynamicLinker;
|
||||||
import jdk.internal.dynalink.DynamicLinkerFactory;
|
import jdk.dynalink.DynamicLinkerFactory;
|
||||||
import jdk.internal.dynalink.linker.ConversionComparator.Comparison;
|
import jdk.dynalink.linker.ConversionComparator.Comparison;
|
||||||
import jdk.internal.dynalink.linker.support.TypeUtilities;
|
import jdk.dynalink.linker.support.TypeUtilities;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Interface for services provided to {@link GuardingDynamicLinker} instances by
|
* Interface for services provided to {@link GuardingDynamicLinker} instances by
|
@ -81,10 +81,10 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker;
|
package jdk.dynalink.linker;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import jdk.internal.dynalink.DynamicLinkerFactory;
|
import jdk.dynalink.DynamicLinkerFactory;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A generic interface describing operations that transform method handles.
|
* A generic interface describing operations that transform method handles.
|
@ -81,11 +81,11 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker;
|
package jdk.dynalink.linker;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import jdk.internal.dynalink.DynamicLinkerFactory;
|
import jdk.dynalink.DynamicLinkerFactory;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Interface for objects representing a strategy for converting a method handle
|
* Interface for objects representing a strategy for converting a method handle
|
@ -81,9 +81,9 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker;
|
package jdk.dynalink.linker;
|
||||||
|
|
||||||
import jdk.internal.dynalink.linker.support.CompositeTypeBasedGuardingDynamicLinker;
|
import jdk.dynalink.linker.support.CompositeTypeBasedGuardingDynamicLinker;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A guarding dynamic linker that can determine whether it can link the call site solely based on the type of the first
|
* A guarding dynamic linker that can determine whether it can link the call site solely based on the type of the first
|
@ -86,32 +86,32 @@
|
|||||||
* Contains interfaces and classes needed by language runtimes to implement
|
* Contains interfaces and classes needed by language runtimes to implement
|
||||||
* their own language-specific object models and type conversions. The main
|
* their own language-specific object models and type conversions. The main
|
||||||
* entry point is the
|
* entry point is the
|
||||||
* {@link jdk.internal.dynalink.linker.GuardingDynamicLinker} interface. It needs to be
|
* {@link jdk.dynalink.linker.GuardingDynamicLinker} interface. It needs to be
|
||||||
* implemented in order to provide linking for the runtime's own object model.
|
* implemented in order to provide linking for the runtime's own object model.
|
||||||
* A language runtime can have more than one guarding dynamic linker
|
* A language runtime can have more than one guarding dynamic linker
|
||||||
* implementation. When a runtime is configuring Dynalink for itself, it will
|
* implementation. When a runtime is configuring Dynalink for itself, it will
|
||||||
* normally set these guarding linkers as the prioritized linkers in its
|
* normally set these guarding linkers as the prioritized linkers in its
|
||||||
* {@link jdk.internal.dynalink.DynamicLinkerFactory} (and maybe some of them as fallback
|
* {@link jdk.dynalink.DynamicLinkerFactory} (and maybe some of them as fallback
|
||||||
* linkers, for e.g. handling "method not found" and similar errors in a
|
* linkers, for e.g. handling "method not found" and similar errors in a
|
||||||
* language-specific manner if no other linker managed to handle the operation.)
|
* language-specific manner if no other linker managed to handle the operation.)
|
||||||
* </p><p>
|
* </p><p>
|
||||||
* A language runtime that wishes to make at least some of its linkers available
|
* A language runtime that wishes to make at least some of its linkers available
|
||||||
* to other language runtimes for interoperability will need to declare the
|
* to other language runtimes for interoperability will need to declare the
|
||||||
* class names of those linkers in
|
* class names of those linkers in
|
||||||
* {@code /META-INF/services/jdk.internal.dynalink.linker.GuardingDynamicLinker} file in
|
* {@code /META-INF/services/jdk.dynalink.linker.GuardingDynamicLinker} file in
|
||||||
* its distribution (typically, JAR file).
|
* its distribution (typically, JAR file).
|
||||||
* </p><p>
|
* </p><p>
|
||||||
* Most language runtimes will be able to implement their own linking logic by
|
* Most language runtimes will be able to implement their own linking logic by
|
||||||
* implementing {@link jdk.internal.dynalink.linker.TypeBasedGuardingDynamicLinker}
|
* implementing {@link jdk.dynalink.linker.TypeBasedGuardingDynamicLinker}
|
||||||
* instead of {@link jdk.internal.dynalink.linker.GuardingDynamicLinker}; it allows for
|
* instead of {@link jdk.dynalink.linker.GuardingDynamicLinker}; it allows for
|
||||||
* faster type-based linking dispatch.
|
* faster type-based linking dispatch.
|
||||||
* </p><p>
|
* </p><p>
|
||||||
* Language runtimes that allow type conversions other than those provided by
|
* Language runtimes that allow type conversions other than those provided by
|
||||||
* Java will need to have their guarding dynamic linker (or linkers) also
|
* Java will need to have their guarding dynamic linker (or linkers) also
|
||||||
* implement the {@link jdk.internal.dynalink.linker.GuardingTypeConverterFactory}
|
* implement the {@link jdk.dynalink.linker.GuardingTypeConverterFactory}
|
||||||
* interface to provide the logic for these conversions.
|
* interface to provide the logic for these conversions.
|
||||||
* </p>
|
* </p>
|
||||||
* @since 1.9
|
* @since 1.9
|
||||||
*/
|
*/
|
||||||
@jdk.Exported
|
@jdk.Exported
|
||||||
package jdk.internal.dynalink.linker;
|
package jdk.dynalink.linker;
|
@ -81,15 +81,15 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker.support;
|
package jdk.dynalink.linker.support;
|
||||||
|
|
||||||
import java.util.LinkedList;
|
import java.util.LinkedList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.GuardingDynamicLinker;
|
import jdk.dynalink.linker.GuardingDynamicLinker;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A {@link GuardingDynamicLinker} that delegates sequentially to a list of
|
* A {@link GuardingDynamicLinker} that delegates sequentially to a list of
|
@ -81,17 +81,17 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker.support;
|
package jdk.dynalink.linker.support;
|
||||||
|
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
import java.util.LinkedList;
|
import java.util.LinkedList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.GuardingDynamicLinker;
|
import jdk.dynalink.linker.GuardingDynamicLinker;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
import jdk.internal.dynalink.linker.TypeBasedGuardingDynamicLinker;
|
import jdk.dynalink.linker.TypeBasedGuardingDynamicLinker;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A composite type-based guarding dynamic linker. When a receiver of a not yet
|
* A composite type-based guarding dynamic linker. When a receiver of a not yet
|
@ -81,13 +81,13 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker.support;
|
package jdk.dynalink.linker.support;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import jdk.internal.dynalink.DynamicLinkerFactory;
|
import jdk.dynalink.DynamicLinkerFactory;
|
||||||
import jdk.internal.dynalink.linker.MethodHandleTransformer;
|
import jdk.dynalink.linker.MethodHandleTransformer;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Default implementation for a
|
* Default implementation for a
|
@ -81,15 +81,15 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker.support;
|
package jdk.dynalink.linker.support;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import java.util.logging.Level;
|
import java.util.logging.Level;
|
||||||
import java.util.logging.Logger;
|
import java.util.logging.Logger;
|
||||||
import jdk.internal.dynalink.DynamicLinker;
|
import jdk.dynalink.DynamicLinker;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Utility methods for creating typical guards for
|
* Utility methods for creating typical guards for
|
||||||
@ -98,7 +98,7 @@ import jdk.internal.dynalink.linker.LinkerServices;
|
|||||||
*/
|
*/
|
||||||
public final class Guards {
|
public final class Guards {
|
||||||
private static final Logger LOG = Logger
|
private static final Logger LOG = Logger
|
||||||
.getLogger(Guards.class.getName(), "jdk.internal.dynalink.support.messages");
|
.getLogger(Guards.class.getName(), "jdk.dynalink.support.messages");
|
||||||
|
|
||||||
private Guards() {
|
private Guards() {
|
||||||
}
|
}
|
@ -81,7 +81,7 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker.support;
|
package jdk.dynalink.linker.support;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
@ -81,11 +81,11 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker.support;
|
package jdk.dynalink.linker.support;
|
||||||
|
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Default simple implementation of {@link LinkRequest}.
|
* Default simple implementation of {@link LinkRequest}.
|
@ -81,15 +81,15 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.linker.support;
|
package jdk.dynalink.linker.support;
|
||||||
|
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.IdentityHashMap;
|
import java.util.IdentityHashMap;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import jdk.internal.dynalink.DynamicLinkerFactory;
|
import jdk.dynalink.DynamicLinkerFactory;
|
||||||
import jdk.internal.dynalink.linker.MethodTypeConversionStrategy;
|
import jdk.dynalink.linker.MethodTypeConversionStrategy;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Various static utility methods for working with Java types.
|
* Various static utility methods for working with Java types.
|
@ -90,4 +90,4 @@
|
|||||||
* @since 1.9
|
* @since 1.9
|
||||||
*/
|
*/
|
||||||
@jdk.Exported
|
@jdk.Exported
|
||||||
package jdk.internal.dynalink.linker.support;
|
package jdk.dynalink.linker.support;
|
@ -83,7 +83,7 @@
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* <p>
|
* <p>
|
||||||
* Dynalink is a library for dynamic linking high-level operations on objects.
|
* Dynalink is a library for dynamic linking of high-level operations on objects.
|
||||||
* These operations include "read a property",
|
* These operations include "read a property",
|
||||||
* "write a property", "invoke a function" and so on. Dynalink is primarily
|
* "write a property", "invoke a function" and so on. Dynalink is primarily
|
||||||
* useful for implementing programming languages where at least some expressions
|
* useful for implementing programming languages where at least some expressions
|
||||||
@ -136,8 +136,8 @@
|
|||||||
* method. A minimalist bootstrap method with Dynalink could look like this:
|
* method. A minimalist bootstrap method with Dynalink could look like this:
|
||||||
* <pre>
|
* <pre>
|
||||||
* import java.lang.invoke.*;
|
* import java.lang.invoke.*;
|
||||||
* import jdk.internal.dynalink.*;
|
* import jdk.dynalink.*;
|
||||||
* import jdk.internal.dynalink.support.*;
|
* import jdk.dynalink.support.*;
|
||||||
*
|
*
|
||||||
* class MyLanguageRuntime {
|
* class MyLanguageRuntime {
|
||||||
* private static final DynamicLinker dynamicLinker = new DynamicLinkerFactory().createLinker();
|
* private static final DynamicLinker dynamicLinker = new DynamicLinkerFactory().createLinker();
|
||||||
@ -155,23 +155,23 @@
|
|||||||
* </pre>
|
* </pre>
|
||||||
* There are several objects of significance in the above code snippet:
|
* There are several objects of significance in the above code snippet:
|
||||||
* <ul>
|
* <ul>
|
||||||
* <li>{@link jdk.internal.dynalink.DynamicLinker} is the main object in Dynalink, it
|
* <li>{@link jdk.dynalink.DynamicLinker} is the main object in Dynalink, it
|
||||||
* coordinates the linking of call sites to method handles that implement the
|
* coordinates the linking of call sites to method handles that implement the
|
||||||
* operations named in them. It is configured and created using a
|
* operations named in them. It is configured and created using a
|
||||||
* {@link jdk.internal.dynalink.DynamicLinkerFactory}.</li>
|
* {@link jdk.dynalink.DynamicLinkerFactory}.</li>
|
||||||
* <li>When the bootstrap method is invoked, it needs to create a
|
* <li>When the bootstrap method is invoked, it needs to create a
|
||||||
* {@link java.lang.invoke.CallSite} object. In Dynalink, these call sites need
|
* {@link java.lang.invoke.CallSite} object. In Dynalink, these call sites need
|
||||||
* to additionally implement the {@link jdk.internal.dynalink.RelinkableCallSite}
|
* to additionally implement the {@link jdk.dynalink.RelinkableCallSite}
|
||||||
* interface. "Relinkable" here alludes to the fact that if the call site
|
* interface. "Relinkable" here alludes to the fact that if the call site
|
||||||
* encounters objects of different types at run time, its target will be changed
|
* encounters objects of different types at run time, its target will be changed
|
||||||
* to a method handle that can perform the operation on the newly encountered
|
* to a method handle that can perform the operation on the newly encountered
|
||||||
* type. {@link jdk.internal.dynalink.support.SimpleRelinkableCallSite} and
|
* type. {@link jdk.dynalink.support.SimpleRelinkableCallSite} and
|
||||||
* {@link jdk.internal.dynalink.support.ChainedCallSite} (not used in the above example)
|
* {@link jdk.dynalink.support.ChainedCallSite} (not used in the above example)
|
||||||
* are two implementations already provided by the library.</li>
|
* are two implementations already provided by the library.</li>
|
||||||
* <li>Dynalink uses {@link jdk.internal.dynalink.CallSiteDescriptor} objects to
|
* <li>Dynalink uses {@link jdk.dynalink.CallSiteDescriptor} objects to
|
||||||
* preserve the parameters to the bootstrap method: the lookup and the method type,
|
* preserve the parameters to the bootstrap method: the lookup and the method type,
|
||||||
* as it will need them whenever it needs to relink a call site.</li>
|
* as it will need them whenever it needs to relink a call site.</li>
|
||||||
* <li>Dynalink uses {@link jdk.internal.dynalink.Operation} objects to express
|
* <li>Dynalink uses {@link jdk.dynalink.Operation} objects to express
|
||||||
* dynamic operations. It does not prescribe how would you encode the operations
|
* dynamic operations. It does not prescribe how would you encode the operations
|
||||||
* in your call site, though. That is why in the above example the
|
* in your call site, though. That is why in the above example the
|
||||||
* {@code parseOperation} function is left empty, and you would be expected to
|
* {@code parseOperation} function is left empty, and you would be expected to
|
||||||
@ -214,7 +214,7 @@
|
|||||||
* The {@code SimpleRelinkableCallSite} we used above only remembers the linkage
|
* The {@code SimpleRelinkableCallSite} we used above only remembers the linkage
|
||||||
* for the last encountered type (it implements what is known as a <i>monomorphic
|
* for the last encountered type (it implements what is known as a <i>monomorphic
|
||||||
* inline cache</i>). Another already provided implementation,
|
* inline cache</i>). Another already provided implementation,
|
||||||
* {@link jdk.internal.dynalink.support.ChainedCallSite} will remember linkages for
|
* {@link jdk.dynalink.support.ChainedCallSite} will remember linkages for
|
||||||
* several different types (it is a <i>polymorphic inline cache</i>) and is
|
* several different types (it is a <i>polymorphic inline cache</i>) and is
|
||||||
* probably a better choice in serious applications.
|
* probably a better choice in serious applications.
|
||||||
* <h2>Dynalink and bytecode creation</h2>
|
* <h2>Dynalink and bytecode creation</h2>
|
||||||
@ -229,11 +229,11 @@
|
|||||||
* (e.g. a typical representation would be some node objects in a syntax tree).
|
* (e.g. a typical representation would be some node objects in a syntax tree).
|
||||||
* <h2>Available operations</h2>
|
* <h2>Available operations</h2>
|
||||||
* Dynalink defines several standard operations in its
|
* Dynalink defines several standard operations in its
|
||||||
* {@link jdk.internal.dynalink.StandardOperation} class. The linker for Java
|
* {@link jdk.dynalink.StandardOperation} class. The linker for Java
|
||||||
* objects can link all of these operations, and you are encouraged to at
|
* objects can link all of these operations, and you are encouraged to at
|
||||||
* minimum support and use these operations in your language too. To associate
|
* minimum support and use these operations in your language too. To associate
|
||||||
* a fixed name with an operation, you can use
|
* a fixed name with an operation, you can use
|
||||||
* {@link jdk.internal.dynalink.NamedOperation} as in the above example where
|
* {@link jdk.dynalink.NamedOperation} as in the above example where
|
||||||
* {@code StandardOperation.GET_PROPERTY} was combined with the name
|
* {@code StandardOperation.GET_PROPERTY} was combined with the name
|
||||||
* {@code "color"} in a {@code NamedOperation} to form a property getter for the
|
* {@code "color"} in a {@code NamedOperation} to form a property getter for the
|
||||||
* property named "color".
|
* property named "color".
|
||||||
@ -242,12 +242,12 @@
|
|||||||
* properties, elements, and methods, and a source language construct might
|
* properties, elements, and methods, and a source language construct might
|
||||||
* address two or three of them. Dynalink supports specifying composite
|
* address two or three of them. Dynalink supports specifying composite
|
||||||
* operations for this purpose using the
|
* operations for this purpose using the
|
||||||
* {@link jdk.internal.dynalink.CompositeOperation} class.
|
* {@link jdk.dynalink.CompositeOperation} class.
|
||||||
* <h2>Language-specific linkers</h2>
|
* <h2>Language-specific linkers</h2>
|
||||||
* Languages that define their own object model different than the JVM
|
* Languages that define their own object model different than the JVM
|
||||||
* class-based model and/or use their own type conversions will need to create
|
* class-based model and/or use their own type conversions will need to create
|
||||||
* their own language-specific linkers. See the {@link jdk.internal.dynalink.linker}
|
* their own language-specific linkers. See the {@link jdk.dynalink.linker}
|
||||||
* package and specifically the {@link jdk.internal.dynalink.linker.GuardingDynamicLinker}
|
* package and specifically the {@link jdk.dynalink.linker.GuardingDynamicLinker}
|
||||||
* interface to get started.
|
* interface to get started.
|
||||||
* <h2>Dynalink and Java objects</h2>
|
* <h2>Dynalink and Java objects</h2>
|
||||||
* The {@code DynamicLinker} objects created by {@code DynamicLinkerFactory} by
|
* The {@code DynamicLinker} objects created by {@code DynamicLinkerFactory} by
|
||||||
@ -256,13 +256,13 @@
|
|||||||
* that implements the usual Java semantics for all of the above operations and
|
* that implements the usual Java semantics for all of the above operations and
|
||||||
* can link any Java object that no other language-specific linker has managed
|
* can link any Java object that no other language-specific linker has managed
|
||||||
* to link. This way, all language runtimes have built-in interoperability with
|
* to link. This way, all language runtimes have built-in interoperability with
|
||||||
* ordinary Java objects. See {@link jdk.internal.dynalink.beans.BeansLinker} for details
|
* ordinary Java objects. See {@link jdk.dynalink.beans.BeansLinker} for details
|
||||||
* on how it links the various operations.
|
* on how it links the various operations.
|
||||||
* <h2>Cross-language interoperability</h2>
|
* <h2>Cross-language interoperability</h2>
|
||||||
* A {@code DynamicLinkerFactory} can be configured with a
|
* A {@code DynamicLinkerFactory} can be configured with a
|
||||||
* {@link jdk.internal.dynalink.DynamicLinkerFactory#setClassLoader(ClassLoader) class
|
* {@link jdk.dynalink.DynamicLinkerFactory#setClassLoader(ClassLoader) class
|
||||||
* loader}. It will try to instantiate all
|
* loader}. It will try to instantiate all
|
||||||
* {@link jdk.internal.dynalink.linker.GuardingDynamicLinkerExporter} classes visible to
|
* {@link jdk.dynalink.linker.GuardingDynamicLinkerExporter} classes visible to
|
||||||
* that class loader and compose the linkers they provide into the
|
* that class loader and compose the linkers they provide into the
|
||||||
* {@code DynamicLinker} it creates. This allows for interoperability between
|
* {@code DynamicLinker} it creates. This allows for interoperability between
|
||||||
* languages: if you have two language runtimes A and B deployed in your JVM and
|
* languages: if you have two language runtimes A and B deployed in your JVM and
|
||||||
@ -274,4 +274,4 @@
|
|||||||
* object from B.
|
* object from B.
|
||||||
*/
|
*/
|
||||||
@jdk.Exported
|
@jdk.Exported
|
||||||
package jdk.internal.dynalink;
|
package jdk.dynalink;
|
@ -81,14 +81,14 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.support;
|
package jdk.dynalink.support;
|
||||||
|
|
||||||
import java.lang.invoke.CallSite;
|
import java.lang.invoke.CallSite;
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MutableCallSite;
|
import java.lang.invoke.MutableCallSite;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.RelinkableCallSite;
|
import jdk.dynalink.RelinkableCallSite;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A basic implementation of the {@link RelinkableCallSite} as a
|
* A basic implementation of the {@link RelinkableCallSite} as a
|
@ -81,16 +81,16 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.support;
|
package jdk.dynalink.support;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
||||||
import java.util.LinkedList;
|
import java.util.LinkedList;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.support.Lookup;
|
import jdk.dynalink.linker.support.Lookup;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A relinkable call site that implements a polymorphic inline caching strategy.
|
* A relinkable call site that implements a polymorphic inline caching strategy.
|
@ -81,12 +81,12 @@
|
|||||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package jdk.internal.dynalink.support;
|
package jdk.dynalink.support;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.DynamicLinker;
|
import jdk.dynalink.DynamicLinker;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A relinkable call site that implements monomorphic inline caching strategy,
|
* A relinkable call site that implements monomorphic inline caching strategy,
|
@ -88,4 +88,4 @@
|
|||||||
* @since 1.9
|
* @since 1.9
|
||||||
*/
|
*/
|
||||||
@jdk.Exported
|
@jdk.Exported
|
||||||
package jdk.internal.dynalink.support;
|
package jdk.dynalink.support;
|
@ -26,8 +26,8 @@
|
|||||||
package jdk.nashorn.api.scripting;
|
package jdk.nashorn.api.scripting;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import jdk.internal.dynalink.beans.StaticClass;
|
import jdk.dynalink.beans.StaticClass;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
import jdk.nashorn.internal.runtime.Context;
|
import jdk.nashorn.internal.runtime.Context;
|
||||||
import jdk.nashorn.internal.runtime.ScriptFunction;
|
import jdk.nashorn.internal.runtime.ScriptFunction;
|
||||||
import jdk.nashorn.internal.runtime.ScriptObject;
|
import jdk.nashorn.internal.runtime.ScriptObject;
|
||||||
|
@ -30,9 +30,9 @@ import static jdk.nashorn.internal.runtime.ECMAErrors.typeError;
|
|||||||
import static jdk.nashorn.internal.runtime.UnwarrantedOptimismException.INVALID_PROGRAM_POINT;
|
import static jdk.nashorn.internal.runtime.UnwarrantedOptimismException.INVALID_PROGRAM_POINT;
|
||||||
import java.nio.ByteBuffer;
|
import java.nio.ByteBuffer;
|
||||||
import java.nio.ByteOrder;
|
import java.nio.ByteOrder;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.nashorn.internal.objects.annotations.Attribute;
|
import jdk.nashorn.internal.objects.annotations.Attribute;
|
||||||
import jdk.nashorn.internal.objects.annotations.Getter;
|
import jdk.nashorn.internal.objects.annotations.Getter;
|
||||||
import jdk.nashorn.internal.objects.annotations.ScriptClass;
|
import jdk.nashorn.internal.objects.annotations.ScriptClass;
|
||||||
|
@ -47,10 +47,10 @@ import java.util.concurrent.Callable;
|
|||||||
import java.util.concurrent.ConcurrentHashMap;
|
import java.util.concurrent.ConcurrentHashMap;
|
||||||
import javax.script.ScriptContext;
|
import javax.script.ScriptContext;
|
||||||
import javax.script.ScriptEngine;
|
import javax.script.ScriptEngine;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.StandardOperation;
|
import jdk.dynalink.StandardOperation;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.nashorn.api.scripting.ClassFilter;
|
import jdk.nashorn.api.scripting.ClassFilter;
|
||||||
import jdk.nashorn.api.scripting.ScriptObjectMirror;
|
import jdk.nashorn.api.scripting.ScriptObjectMirror;
|
||||||
import jdk.nashorn.internal.lookup.Lookup;
|
import jdk.nashorn.internal.lookup.Lookup;
|
||||||
|
@ -42,9 +42,9 @@ import java.util.Comparator;
|
|||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.concurrent.Callable;
|
import java.util.concurrent.Callable;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.nashorn.api.scripting.JSObject;
|
import jdk.nashorn.api.scripting.JSObject;
|
||||||
import jdk.nashorn.internal.objects.annotations.Attribute;
|
import jdk.nashorn.internal.objects.annotations.Attribute;
|
||||||
import jdk.nashorn.internal.objects.annotations.Constructor;
|
import jdk.nashorn.internal.objects.annotations.Constructor;
|
||||||
|
@ -31,8 +31,8 @@ import static jdk.nashorn.internal.runtime.ECMAErrors.typeError;
|
|||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.nashorn.internal.objects.annotations.Attribute;
|
import jdk.nashorn.internal.objects.annotations.Attribute;
|
||||||
import jdk.nashorn.internal.objects.annotations.Constructor;
|
import jdk.nashorn.internal.objects.annotations.Constructor;
|
||||||
import jdk.nashorn.internal.objects.annotations.Function;
|
import jdk.nashorn.internal.objects.annotations.Function;
|
||||||
|
@ -33,7 +33,7 @@ import static jdk.nashorn.internal.runtime.Source.sourceFor;
|
|||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import jdk.internal.dynalink.linker.support.Lookup;
|
import jdk.dynalink.linker.support.Lookup;
|
||||||
import jdk.nashorn.api.scripting.JSObject;
|
import jdk.nashorn.api.scripting.JSObject;
|
||||||
import jdk.nashorn.internal.objects.annotations.Attribute;
|
import jdk.nashorn.internal.objects.annotations.Attribute;
|
||||||
import jdk.nashorn.internal.objects.annotations.Constructor;
|
import jdk.nashorn.internal.objects.annotations.Constructor;
|
||||||
|
@ -36,10 +36,10 @@ import java.lang.invoke.MethodType;
|
|||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.StandardOperation;
|
import jdk.dynalink.StandardOperation;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.nashorn.internal.lookup.Lookup;
|
import jdk.nashorn.internal.lookup.Lookup;
|
||||||
import jdk.nashorn.internal.objects.annotations.Constructor;
|
import jdk.nashorn.internal.objects.annotations.Constructor;
|
||||||
import jdk.nashorn.internal.objects.annotations.ScriptClass;
|
import jdk.nashorn.internal.objects.annotations.ScriptClass;
|
||||||
|
@ -37,9 +37,9 @@ import java.util.Deque;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.Queue;
|
import java.util.Queue;
|
||||||
import jdk.internal.dynalink.beans.BeansLinker;
|
import jdk.dynalink.beans.BeansLinker;
|
||||||
import jdk.internal.dynalink.beans.StaticClass;
|
import jdk.dynalink.beans.StaticClass;
|
||||||
import jdk.internal.dynalink.linker.support.TypeUtilities;
|
import jdk.dynalink.linker.support.TypeUtilities;
|
||||||
import jdk.nashorn.api.scripting.JSObject;
|
import jdk.nashorn.api.scripting.JSObject;
|
||||||
import jdk.nashorn.api.scripting.ScriptObjectMirror;
|
import jdk.nashorn.api.scripting.ScriptObjectMirror;
|
||||||
import jdk.nashorn.internal.objects.annotations.Attribute;
|
import jdk.nashorn.internal.objects.annotations.Attribute;
|
||||||
|
@ -28,10 +28,10 @@ package jdk.nashorn.internal.objects;
|
|||||||
import static jdk.nashorn.internal.runtime.ECMAErrors.typeError;
|
import static jdk.nashorn.internal.runtime.ECMAErrors.typeError;
|
||||||
import static jdk.nashorn.internal.runtime.UnwarrantedOptimismException.isValid;
|
import static jdk.nashorn.internal.runtime.UnwarrantedOptimismException.isValid;
|
||||||
|
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.beans.StaticClass;
|
import jdk.dynalink.beans.StaticClass;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.nashorn.internal.objects.annotations.Attribute;
|
import jdk.nashorn.internal.objects.annotations.Attribute;
|
||||||
import jdk.nashorn.internal.objects.annotations.Constructor;
|
import jdk.nashorn.internal.objects.annotations.Constructor;
|
||||||
import jdk.nashorn.internal.objects.annotations.Function;
|
import jdk.nashorn.internal.objects.annotations.Function;
|
||||||
|
@ -36,8 +36,8 @@ import java.lang.invoke.MethodType;
|
|||||||
import java.math.RoundingMode;
|
import java.math.RoundingMode;
|
||||||
import java.text.NumberFormat;
|
import java.text.NumberFormat;
|
||||||
import java.util.Locale;
|
import java.util.Locale;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.nashorn.internal.objects.annotations.Attribute;
|
import jdk.nashorn.internal.objects.annotations.Attribute;
|
||||||
import jdk.nashorn.internal.objects.annotations.Constructor;
|
import jdk.nashorn.internal.objects.annotations.Constructor;
|
||||||
import jdk.nashorn.internal.objects.annotations.Function;
|
import jdk.nashorn.internal.objects.annotations.Function;
|
||||||
|
@ -39,16 +39,16 @@ import java.util.HashSet;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
import java.util.concurrent.Callable;
|
import java.util.concurrent.Callable;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.NamedOperation;
|
import jdk.dynalink.NamedOperation;
|
||||||
import jdk.internal.dynalink.Operation;
|
import jdk.dynalink.Operation;
|
||||||
import jdk.internal.dynalink.StandardOperation;
|
import jdk.dynalink.StandardOperation;
|
||||||
import jdk.internal.dynalink.beans.BeansLinker;
|
import jdk.dynalink.beans.BeansLinker;
|
||||||
import jdk.internal.dynalink.beans.StaticClass;
|
import jdk.dynalink.beans.StaticClass;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.GuardingDynamicLinker;
|
import jdk.dynalink.linker.GuardingDynamicLinker;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.internal.dynalink.linker.support.SimpleLinkRequest;
|
import jdk.dynalink.linker.support.SimpleLinkRequest;
|
||||||
import jdk.nashorn.api.scripting.ScriptObjectMirror;
|
import jdk.nashorn.api.scripting.ScriptObjectMirror;
|
||||||
import jdk.nashorn.internal.lookup.Lookup;
|
import jdk.nashorn.internal.lookup.Lookup;
|
||||||
import jdk.nashorn.internal.objects.annotations.Attribute;
|
import jdk.nashorn.internal.objects.annotations.Attribute;
|
||||||
|
@ -41,10 +41,10 @@ import java.util.LinkedList;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Locale;
|
import java.util.Locale;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.StandardOperation;
|
import jdk.dynalink.StandardOperation;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.nashorn.internal.lookup.MethodHandleFactory.LookupException;
|
import jdk.nashorn.internal.lookup.MethodHandleFactory.LookupException;
|
||||||
import jdk.nashorn.internal.objects.annotations.Attribute;
|
import jdk.nashorn.internal.objects.annotations.Attribute;
|
||||||
import jdk.nashorn.internal.objects.annotations.Constructor;
|
import jdk.nashorn.internal.objects.annotations.Constructor;
|
||||||
|
@ -30,8 +30,8 @@ import java.lang.annotation.Retention;
|
|||||||
import java.lang.annotation.RetentionPolicy;
|
import java.lang.annotation.RetentionPolicy;
|
||||||
import java.lang.annotation.Target;
|
import java.lang.annotation.Target;
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.nashorn.internal.runtime.ScriptFunction;
|
import jdk.nashorn.internal.runtime.ScriptFunction;
|
||||||
import jdk.nashorn.internal.runtime.UnwarrantedOptimismException;
|
import jdk.nashorn.internal.runtime.UnwarrantedOptimismException;
|
||||||
|
|
||||||
|
@ -3068,7 +3068,7 @@ loop:
|
|||||||
if (k < stream.last() && start < parserState.position && parserState.position <= Token.descPosition(stream.get(stream.last()))) {
|
if (k < stream.last() && start < parserState.position && parserState.position <= Token.descPosition(stream.get(stream.last()))) {
|
||||||
// RBRACE is already in the token stream, so fast forward to it
|
// RBRACE is already in the token stream, so fast forward to it
|
||||||
for (; k < stream.last(); k++) {
|
for (; k < stream.last(); k++) {
|
||||||
long nextToken = stream.get(k + 1);
|
final long nextToken = stream.get(k + 1);
|
||||||
if (Token.descPosition(nextToken) == parserState.position && Token.descType(nextToken) == RBRACE) {
|
if (Token.descPosition(nextToken) == parserState.position && Token.descType(nextToken) == RBRACE) {
|
||||||
token = stream.get(k);
|
token = stream.get(k);
|
||||||
type = Token.descType(token);
|
type = Token.descType(token);
|
||||||
@ -3484,7 +3484,7 @@ loop:
|
|||||||
Expression concat = literal;
|
Expression concat = literal;
|
||||||
TokenType lastLiteralType;
|
TokenType lastLiteralType;
|
||||||
do {
|
do {
|
||||||
Expression expression = expression();
|
final Expression expression = expression();
|
||||||
if (type != TEMPLATE_MIDDLE && type != TEMPLATE_TAIL) {
|
if (type != TEMPLATE_MIDDLE && type != TEMPLATE_TAIL) {
|
||||||
throw error(AbstractParser.message("unterminated.template.expression"), token);
|
throw error(AbstractParser.message("unterminated.template.expression"), token);
|
||||||
}
|
}
|
||||||
@ -3515,7 +3515,7 @@ loop:
|
|||||||
if (hasSubstitutions) {
|
if (hasSubstitutions) {
|
||||||
TokenType lastLiteralType;
|
TokenType lastLiteralType;
|
||||||
do {
|
do {
|
||||||
Expression expression = expression();
|
final Expression expression = expression();
|
||||||
if (type != TEMPLATE_MIDDLE && type != TEMPLATE_TAIL) {
|
if (type != TEMPLATE_MIDDLE && type != TEMPLATE_TAIL) {
|
||||||
throw error(AbstractParser.message("unterminated.template.expression"), token);
|
throw error(AbstractParser.message("unterminated.template.expression"), token);
|
||||||
}
|
}
|
||||||
|
@ -43,7 +43,7 @@ import java.util.Map;
|
|||||||
import java.util.TreeMap;
|
import java.util.TreeMap;
|
||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
import java.util.logging.Level;
|
import java.util.logging.Level;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.nashorn.internal.codegen.Compiler;
|
import jdk.nashorn.internal.codegen.Compiler;
|
||||||
import jdk.nashorn.internal.codegen.Compiler.CompilationPhases;
|
import jdk.nashorn.internal.codegen.Compiler.CompilationPhases;
|
||||||
import jdk.nashorn.internal.codegen.TypeMap;
|
import jdk.nashorn.internal.codegen.TypeMap;
|
||||||
|
@ -71,7 +71,7 @@ import java.util.function.Consumer;
|
|||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
import java.util.logging.Level;
|
import java.util.logging.Level;
|
||||||
import javax.script.ScriptEngine;
|
import javax.script.ScriptEngine;
|
||||||
import jdk.internal.dynalink.DynamicLinker;
|
import jdk.dynalink.DynamicLinker;
|
||||||
import jdk.internal.org.objectweb.asm.ClassReader;
|
import jdk.internal.org.objectweb.asm.ClassReader;
|
||||||
import jdk.internal.org.objectweb.asm.ClassWriter;
|
import jdk.internal.org.objectweb.asm.ClassWriter;
|
||||||
import jdk.internal.org.objectweb.asm.Opcodes;
|
import jdk.internal.org.objectweb.asm.Opcodes;
|
||||||
|
@ -29,7 +29,7 @@ import static jdk.nashorn.internal.lookup.Lookup.MH;
|
|||||||
import static jdk.nashorn.internal.runtime.UnwarrantedOptimismException.isValid;
|
import static jdk.nashorn.internal.runtime.UnwarrantedOptimismException.isValid;
|
||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.nashorn.internal.codegen.ObjectClassGenerator;
|
import jdk.nashorn.internal.codegen.ObjectClassGenerator;
|
||||||
import jdk.nashorn.internal.objects.Global;
|
import jdk.nashorn.internal.objects.Global;
|
||||||
|
|
||||||
|
@ -40,10 +40,10 @@ import java.util.HashMap;
|
|||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.concurrent.atomic.AtomicBoolean;
|
import java.util.concurrent.atomic.AtomicBoolean;
|
||||||
import java.util.logging.Level;
|
import java.util.logging.Level;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.DynamicLinker;
|
import jdk.dynalink.DynamicLinker;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.nashorn.internal.lookup.Lookup;
|
import jdk.nashorn.internal.lookup.Lookup;
|
||||||
import jdk.nashorn.internal.lookup.MethodHandleFactory;
|
import jdk.nashorn.internal.lookup.MethodHandleFactory;
|
||||||
import jdk.nashorn.internal.runtime.linker.NashornCallSiteDescriptor;
|
import jdk.nashorn.internal.runtime.linker.NashornCallSiteDescriptor;
|
||||||
|
@ -35,7 +35,7 @@ import java.lang.reflect.Array;
|
|||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import jdk.internal.dynalink.beans.StaticClass;
|
import jdk.dynalink.beans.StaticClass;
|
||||||
import jdk.nashorn.api.scripting.JSObject;
|
import jdk.nashorn.api.scripting.JSObject;
|
||||||
import jdk.nashorn.internal.codegen.CompilerConstants.Call;
|
import jdk.nashorn.internal.codegen.CompilerConstants.Call;
|
||||||
import jdk.nashorn.internal.codegen.types.Type;
|
import jdk.nashorn.internal.codegen.types.Type;
|
||||||
|
@ -31,12 +31,12 @@ import static jdk.nashorn.internal.runtime.UnwarrantedOptimismException.isValid;
|
|||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.beans.BeansLinker;
|
import jdk.dynalink.beans.BeansLinker;
|
||||||
import jdk.internal.dynalink.beans.StaticClass;
|
import jdk.dynalink.beans.StaticClass;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.internal.dynalink.linker.support.Guards;
|
import jdk.dynalink.linker.support.Guards;
|
||||||
import jdk.nashorn.internal.lookup.MethodHandleFactory;
|
import jdk.nashorn.internal.lookup.MethodHandleFactory;
|
||||||
import jdk.nashorn.internal.lookup.MethodHandleFunctionality;
|
import jdk.nashorn.internal.lookup.MethodHandleFunctionality;
|
||||||
import jdk.nashorn.internal.objects.annotations.Attribute;
|
import jdk.nashorn.internal.objects.annotations.Attribute;
|
||||||
|
@ -32,9 +32,9 @@ import static jdk.nashorn.internal.runtime.UnwarrantedOptimismException.isValid;
|
|||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.support.TypeUtilities;
|
import jdk.dynalink.linker.support.TypeUtilities;
|
||||||
import jdk.nashorn.internal.codegen.types.Type;
|
import jdk.nashorn.internal.codegen.types.Type;
|
||||||
import jdk.nashorn.internal.runtime.linker.NashornCallSiteDescriptor;
|
import jdk.nashorn.internal.runtime.linker.NashornCallSiteDescriptor;
|
||||||
|
|
||||||
|
@ -44,10 +44,10 @@ import java.util.Collections;
|
|||||||
import java.util.HashSet;
|
import java.util.HashSet;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.concurrent.atomic.LongAdder;
|
import java.util.concurrent.atomic.LongAdder;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.internal.dynalink.linker.support.Guards;
|
import jdk.dynalink.linker.support.Guards;
|
||||||
import jdk.nashorn.internal.codegen.ApplySpecialization;
|
import jdk.nashorn.internal.codegen.ApplySpecialization;
|
||||||
import jdk.nashorn.internal.codegen.Compiler;
|
import jdk.nashorn.internal.codegen.Compiler;
|
||||||
import jdk.nashorn.internal.codegen.CompilerConstants.Call;
|
import jdk.nashorn.internal.codegen.CompilerConstants.Call;
|
||||||
|
@ -66,11 +66,11 @@ import java.util.List;
|
|||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
import java.util.concurrent.atomic.LongAdder;
|
import java.util.concurrent.atomic.LongAdder;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.NamedOperation;
|
import jdk.dynalink.NamedOperation;
|
||||||
import jdk.internal.dynalink.StandardOperation;
|
import jdk.dynalink.StandardOperation;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.nashorn.internal.codegen.CompilerConstants.Call;
|
import jdk.nashorn.internal.codegen.CompilerConstants.Call;
|
||||||
import jdk.nashorn.internal.codegen.ObjectClassGenerator;
|
import jdk.nashorn.internal.codegen.ObjectClassGenerator;
|
||||||
import jdk.nashorn.internal.codegen.types.Type;
|
import jdk.nashorn.internal.codegen.types.Type;
|
||||||
|
@ -45,8 +45,7 @@ import java.util.Locale;
|
|||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.NoSuchElementException;
|
import java.util.NoSuchElementException;
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
import jdk.dynalink.beans.StaticClass;
|
||||||
import jdk.internal.dynalink.beans.StaticClass;
|
|
||||||
import jdk.nashorn.api.scripting.JSObject;
|
import jdk.nashorn.api.scripting.JSObject;
|
||||||
import jdk.nashorn.api.scripting.ScriptObjectMirror;
|
import jdk.nashorn.api.scripting.ScriptObjectMirror;
|
||||||
import jdk.nashorn.internal.codegen.ApplySpecialization;
|
import jdk.nashorn.internal.codegen.ApplySpecialization;
|
||||||
|
@ -31,15 +31,15 @@ import static jdk.nashorn.internal.runtime.JSType.getAccessorTypeIndex;
|
|||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.SwitchPoint;
|
import java.lang.invoke.SwitchPoint;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.nashorn.internal.runtime.linker.NashornCallSiteDescriptor;
|
import jdk.nashorn.internal.runtime.linker.NashornCallSiteDescriptor;
|
||||||
import jdk.nashorn.internal.runtime.linker.NashornGuards;
|
import jdk.nashorn.internal.runtime.linker.NashornGuards;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Instances of this class are quite ephemeral; they only exist for the duration of an invocation of
|
* Instances of this class are quite ephemeral; they only exist for the duration of an invocation of
|
||||||
* {@link ScriptObject#findSetMethod(CallSiteDescriptor, jdk.internal.dynalink.linker.LinkRequest)} and
|
* {@link ScriptObject#findSetMethod(CallSiteDescriptor, jdk.dynalink.linker.LinkRequest)} and
|
||||||
* serve as the actual encapsulation of the algorithm for creating an appropriate property setter method.
|
* serve as the actual encapsulation of the algorithm for creating an appropriate property setter method.
|
||||||
*/
|
*/
|
||||||
final class SetMethodCreator {
|
final class SetMethodCreator {
|
||||||
|
@ -30,11 +30,11 @@ import static jdk.nashorn.internal.runtime.ECMAErrors.typeError;
|
|||||||
|
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.NamedOperation;
|
import jdk.dynalink.NamedOperation;
|
||||||
import jdk.internal.dynalink.StandardOperation;
|
import jdk.dynalink.StandardOperation;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.support.Guards;
|
import jdk.dynalink.linker.support.Guards;
|
||||||
import jdk.nashorn.internal.runtime.linker.NashornCallSiteDescriptor;
|
import jdk.nashorn.internal.runtime.linker.NashornCallSiteDescriptor;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -32,12 +32,12 @@ import java.lang.invoke.MethodHandle;
|
|||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import java.lang.invoke.SwitchPoint;
|
import java.lang.invoke.SwitchPoint;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.NamedOperation;
|
import jdk.dynalink.NamedOperation;
|
||||||
import jdk.internal.dynalink.Operation;
|
import jdk.dynalink.Operation;
|
||||||
import jdk.internal.dynalink.StandardOperation;
|
import jdk.dynalink.StandardOperation;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.nashorn.api.scripting.AbstractJSObject;
|
import jdk.nashorn.api.scripting.AbstractJSObject;
|
||||||
import jdk.nashorn.api.scripting.ScriptObjectMirror;
|
import jdk.nashorn.api.scripting.ScriptObjectMirror;
|
||||||
import jdk.nashorn.internal.runtime.linker.NashornCallSiteDescriptor;
|
import jdk.nashorn.internal.runtime.linker.NashornCallSiteDescriptor;
|
||||||
|
@ -34,9 +34,9 @@ import java.nio.ByteBuffer;
|
|||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.nashorn.internal.codegen.CompilerConstants;
|
import jdk.nashorn.internal.codegen.CompilerConstants;
|
||||||
import jdk.nashorn.internal.codegen.types.Type;
|
import jdk.nashorn.internal.codegen.types.Type;
|
||||||
import jdk.nashorn.internal.objects.Global;
|
import jdk.nashorn.internal.objects.Global;
|
||||||
|
@ -33,9 +33,9 @@ import java.lang.invoke.MethodHandle;
|
|||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import java.lang.invoke.SwitchPoint;
|
import java.lang.invoke.SwitchPoint;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.nashorn.internal.codegen.types.Type;
|
import jdk.nashorn.internal.codegen.types.Type;
|
||||||
import jdk.nashorn.internal.lookup.Lookup;
|
import jdk.nashorn.internal.lookup.Lookup;
|
||||||
import jdk.nashorn.internal.runtime.ScriptObject;
|
import jdk.nashorn.internal.runtime.ScriptObject;
|
||||||
|
@ -32,7 +32,7 @@ import static jdk.nashorn.internal.runtime.ScriptRuntime.UNDEFINED;
|
|||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import jdk.internal.dynalink.linker.support.TypeUtilities;
|
import jdk.dynalink.linker.support.TypeUtilities;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Implementation of {@link ArrayData} as soon as a double has been
|
* Implementation of {@link ArrayData} as soon as a double has been
|
||||||
|
@ -28,9 +28,9 @@ package jdk.nashorn.internal.runtime.arrays;
|
|||||||
import static jdk.nashorn.internal.lookup.Lookup.MH;
|
import static jdk.nashorn.internal.lookup.Lookup.MH;
|
||||||
import java.lang.invoke.MethodHandle;
|
import java.lang.invoke.MethodHandle;
|
||||||
import java.nio.Buffer;
|
import java.nio.Buffer;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.nashorn.internal.lookup.Lookup;
|
import jdk.nashorn.internal.lookup.Lookup;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -34,17 +34,17 @@ import java.lang.invoke.MethodHandle;
|
|||||||
import java.lang.invoke.MethodHandles;
|
import java.lang.invoke.MethodHandles;
|
||||||
import java.lang.invoke.MethodHandles.Lookup;
|
import java.lang.invoke.MethodHandles.Lookup;
|
||||||
import java.lang.invoke.MethodType;
|
import java.lang.invoke.MethodType;
|
||||||
import jdk.internal.dynalink.CallSiteDescriptor;
|
import jdk.dynalink.CallSiteDescriptor;
|
||||||
import jdk.internal.dynalink.DynamicLinker;
|
import jdk.dynalink.DynamicLinker;
|
||||||
import jdk.internal.dynalink.DynamicLinkerFactory;
|
import jdk.dynalink.DynamicLinkerFactory;
|
||||||
import jdk.internal.dynalink.beans.BeansLinker;
|
import jdk.dynalink.beans.BeansLinker;
|
||||||
import jdk.internal.dynalink.beans.StaticClass;
|
import jdk.dynalink.beans.StaticClass;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocation;
|
import jdk.dynalink.linker.GuardedInvocation;
|
||||||
import jdk.internal.dynalink.linker.GuardedInvocationTransformer;
|
import jdk.dynalink.linker.GuardedInvocationTransformer;
|
||||||
import jdk.internal.dynalink.linker.LinkRequest;
|
import jdk.dynalink.linker.LinkRequest;
|
||||||
import jdk.internal.dynalink.linker.LinkerServices;
|
import jdk.dynalink.linker.LinkerServices;
|
||||||
import jdk.internal.dynalink.linker.MethodTypeConversionStrategy;
|
import jdk.dynalink.linker.MethodTypeConversionStrategy;
|
||||||
import jdk.internal.dynalink.linker.support.TypeUtilities;
|
import jdk.dynalink.linker.support.TypeUtilities;
|
||||||
import jdk.nashorn.api.scripting.JSObject;
|
import jdk.nashorn.api.scripting.JSObject;
|
||||||
import jdk.nashorn.internal.codegen.CompilerConstants.Call;
|
import jdk.nashorn.internal.codegen.CompilerConstants.Call;
|
||||||
import jdk.nashorn.internal.lookup.MethodHandleFactory;
|
import jdk.nashorn.internal.lookup.MethodHandleFactory;
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user