| java.lang.Object org.apache.jk.core.JkHandler org.apache.jk.apr.AprImpl
AprImpl | public class AprImpl extends JkHandler (Code) | | Implements the interface with the APR library. This is for internal-use
only. The goal is to use 'natural' mappings for user code - for example
java.net.Socket for unix-domain sockets, etc.
|
Constructor Summary | |
public | AprImpl() |
Method Summary | |
public void | addJkHandler(String type, JkHandler cb) Add a Handler for jni callbacks. | public static Object | createJavaContext(String type, long cContext) | native public long | createJkHandler(long xEnv, String compName) | public static byte[] | getBuffer(Object ctx, int id) Return a buffer associated with the ctx. | native public long | getJkEnv() | native public long | getJkHandler(long xEnv, String compName) | public void | init() | native public int | initialize() | public boolean | isLoaded() | native public int | jkDestroy(long xEnv, long componentP) | native public String | jkGetAttribute(long xEnv, long componentP, String name) | native public int | jkInit(long xEnv, long componentP) | native public static int | jkInvoke(long xEnv, long componentP, long endpointP, int code, byte data, int off, int len, int raw) Send the packet to the C side. | native public void | jkRecycle(long xEnv, long endpointP) Recycle an endpoint after use. | native public int | jkSetAttribute(long xEnv, long componentP, String name, String val) | public static int | jniInvoke(long jContext, Object ctx) | public static void | jniMode() | public void | loadNative() This method of loading the libs doesn't require setting
LD_LIBRARY_PATH. | public void | loadNative(String libPath) | native public void | releaseJkEnv(long xEnv) | public void | setAprHome(String s) | public void | setBaseDir(String s) Native libraries are located based on base dir. | public static void | setErr(String filename) | public void | setJniModeSo(String jniModeSo) | public void | setNativeSo(String nativeSo) name of the so used by java. | public static void | setOut(String filename) | public void | setSoExt(String s) | native public int | terminate() |
initialized | boolean initialized(Code) | | |
jniMode | static boolean jniMode(Code) | | |
createJkHandler | native public long createJkHandler(long xEnv, String compName)(Code) | | |
getBuffer | public static byte[] getBuffer(Object ctx, int id)(Code) | | Return a buffer associated with the ctx.
|
getJkEnv | native public long getJkEnv()(Code) | | |
getJkHandler | native public long getJkHandler(long xEnv, String compName)(Code) | | Get a native component
0 if the component is not found. |
initialize | native public int initialize()(Code) | | Initialize APR
|
isLoaded | public boolean isLoaded()(Code) | | |
jkDestroy | native public int jkDestroy(long xEnv, long componentP)(Code) | | |
jkGetAttribute | native public String jkGetAttribute(long xEnv, long componentP, String name)(Code) | | |
jkInit | native public int jkInit(long xEnv, long componentP)(Code) | | |
jkInvoke | native public static int jkInvoke(long xEnv, long componentP, long endpointP, int code, byte data, int off, int len, int raw)(Code) | | Send the packet to the C side. On return it contains the response
or indication there is no response. Asymetrical because we can't
do things like continuations.
|
jkRecycle | native public void jkRecycle(long xEnv, long endpointP)(Code) | | Recycle an endpoint after use.
|
jkSetAttribute | native public int jkSetAttribute(long xEnv, long componentP, String name, String val)(Code) | | |
jniInvoke | public static int jniInvoke(long jContext, Object ctx)(Code) | | |
jniMode | public static void jniMode()(Code) | | |
loadNative | public void loadNative() throws Throwable(Code) | | This method of loading the libs doesn't require setting
LD_LIBRARY_PATH. Assuming a 'right' binary distribution,
or a correct build all files will be in their right place.
The burden is on our code to deal with platform specific
extensions and to keep the paths consistent - not easy, but
worth it if it avoids one extra step for the user.
Of course, this can change to System.load() and putting the
libs in LD_LIBRARY_PATH.
|
releaseJkEnv | native public void releaseJkEnv(long xEnv)(Code) | | Clean the temp pool, put back the env in the pool
|
setBaseDir | public void setBaseDir(String s)(Code) | | Native libraries are located based on base dir.
XXX Add platform, version, etc
|
setErr | public static void setErr(String filename)(Code) | | Sets the System.err stream
|
setJniModeSo | public void setJniModeSo(String jniModeSo)(Code) | | Name of the so used in inprocess mode
|
setNativeSo | public void setNativeSo(String nativeSo)(Code) | | name of the so used by java. If not set we'll loadLibrary("jkjni" ),
if set we load( nativeSo )
|
setOut | public static void setOut(String filename)(Code) | | Sets the System.out stream
|
terminate | native public int terminate()(Code) | | |
|
|