Mercurial > hg > graal-jvmci-8
comparison graal/com.oracle.nfi/src/com/oracle/nfi/api/NativeFunctionInterface.java @ 16966:e92bc7d8e2dd
NFI: adopt JavaDoc
author | Matthias Grimmer <grimmer@ssw.jku.at> |
---|---|
date | Wed, 27 Aug 2014 09:14:19 +0200 |
parents | dd8449afc086 |
children | 2f92172fa320 |
comparison
equal
deleted
inserted
replaced
16965:c0376739e835 | 16966:e92bc7d8e2dd |
---|---|
49 /** | 49 /** |
50 * Resolves the function pointer {@code NativeFunctionPointer} of a native function. | 50 * Resolves the function pointer {@code NativeFunctionPointer} of a native function. |
51 * | 51 * |
52 * @param libraries the ordered list of libraries to search for the function | 52 * @param libraries the ordered list of libraries to search for the function |
53 * @param name the name of the function to be resolved | 53 * @param name the name of the function to be resolved |
54 * @return a pointer to the native function | 54 * @return a pointer to the native function, or <code>null</code> if the function pointer could |
55 * @throws UnsatisfiedLinkError if the function could not be resolved | 55 * not be resolved |
56 */ | 56 */ |
57 NativeFunctionPointer getFunctionPointer(NativeLibraryHandle[] libraries, String name); | 57 NativeFunctionPointer getFunctionPointer(NativeLibraryHandle[] libraries, String name); |
58 | 58 |
59 /** | 59 /** |
60 * Resolves a function name to a {@linkplain NativeFunctionHandle handle} that can be called | 60 * Resolves a function name to a {@linkplain NativeFunctionHandle handle} that can be called |
63 * | 63 * |
64 * @param library the handle to a resolved library | 64 * @param library the handle to a resolved library |
65 * @param name the name of the function to be resolved | 65 * @param name the name of the function to be resolved |
66 * @param returnType the type of the return value | 66 * @param returnType the type of the return value |
67 * @param argumentTypes the types of the arguments | 67 * @param argumentTypes the types of the arguments |
68 * @return the function handle of the native function | 68 * @return the function handle of the native function, or <code>null</code> if the function |
69 * @throws UnsatisfiedLinkError if the function handle could not be resolved | 69 * handle could not be resolved |
70 */ | 70 */ |
71 NativeFunctionHandle getFunctionHandle(NativeLibraryHandle library, String name, Class<?> returnType, Class<?>... argumentTypes); | 71 NativeFunctionHandle getFunctionHandle(NativeLibraryHandle library, String name, Class<?> returnType, Class<?>... argumentTypes); |
72 | 72 |
73 /** | 73 /** |
74 * Resolves a function pointer to a {@linkplain NativeFunctionHandle handle} that can be called | 74 * Resolves a function pointer to a {@linkplain NativeFunctionHandle handle} that can be called |
76 * to the handle when it is {@linkplain NativeFunctionHandle#call(Object...) called}. | 76 * to the handle when it is {@linkplain NativeFunctionHandle#call(Object...) called}. |
77 * | 77 * |
78 * @param functionPointer a function pointer | 78 * @param functionPointer a function pointer |
79 * @param returnType the type of the return value | 79 * @param returnType the type of the return value |
80 * @param argumentTypes the types of the arguments | 80 * @param argumentTypes the types of the arguments |
81 * @return the function handle of the native function | 81 * @return the function handle of the native function, or <code>null</code> if the function |
82 * @throws UnsatisfiedLinkError the function handle could not be created | 82 * handle could not be resolved |
83 */ | 83 */ |
84 NativeFunctionHandle getFunctionHandle(NativeFunctionPointer functionPointer, Class<?> returnType, Class<?>... argumentTypes); | 84 NativeFunctionHandle getFunctionHandle(NativeFunctionPointer functionPointer, Class<?> returnType, Class<?>... argumentTypes); |
85 | 85 |
86 /** | 86 /** |
87 * Resolves a function name to a {@linkplain NativeFunctionHandle handle} that can be called | 87 * Resolves a function name to a {@linkplain NativeFunctionHandle handle} that can be called |
90 * | 90 * |
91 * @param libraries the ordered list of libraries to search for the function | 91 * @param libraries the ordered list of libraries to search for the function |
92 * @param name the name of the function to be resolved | 92 * @param name the name of the function to be resolved |
93 * @param returnType the type of the return value | 93 * @param returnType the type of the return value |
94 * @param argumentTypes the types of the arguments | 94 * @param argumentTypes the types of the arguments |
95 * @return the function handle of the native function | 95 * @return the function handle of the native function, or <code>null</code> if the function |
96 * @throws UnsatisfiedLinkError if the function handle could not be created | 96 * handle could not be resolved |
97 */ | 97 */ |
98 NativeFunctionHandle getFunctionHandle(NativeLibraryHandle[] libraries, String name, Class<?> returnType, Class<?>... argumentTypes); | 98 NativeFunctionHandle getFunctionHandle(NativeLibraryHandle[] libraries, String name, Class<?> returnType, Class<?>... argumentTypes); |
99 | 99 |
100 /** | 100 /** |
101 * Resolves a function name to a {@linkplain NativeFunctionHandle handle} that can be called | 101 * Resolves a function name to a {@linkplain NativeFunctionHandle handle} that can be called |
103 * to the handle when it is {@linkplain NativeFunctionHandle#call(Object...) called}. | 103 * to the handle when it is {@linkplain NativeFunctionHandle#call(Object...) called}. |
104 * | 104 * |
105 * @param name the name of the function to be resolved | 105 * @param name the name of the function to be resolved |
106 * @param returnType the type of the return value | 106 * @param returnType the type of the return value |
107 * @param argumentTypes the types of the arguments | 107 * @param argumentTypes the types of the arguments |
108 * @return the function handle of the native function | 108 * @return the function handle of the native function, or <code>null</code> if default library |
109 * @throws UnsatisfiedLinkError if default library searching is not | 109 * searching is not {@linkplain #isDefaultLibrarySearchSupported() supported} or if the |
110 * {@linkplain #isDefaultLibrarySearchSupported() supported} or if the function | 110 * function could not be resolved |
111 * could not be resolved | |
112 */ | 111 */ |
113 NativeFunctionHandle getFunctionHandle(String name, Class<?> returnType, Class<?>... argumentTypes); | 112 NativeFunctionHandle getFunctionHandle(String name, Class<?> returnType, Class<?>... argumentTypes); |
114 | 113 |
115 /** | 114 /** |
116 * Creates a {@link NativeFunctionPointer} from a raw value. | 115 * Creates a {@link NativeFunctionPointer} from a raw value. |