| java.lang.Object org.apache.tomcat.jni.Procattr
Procattr | public class Procattr (Code) | | Procattr
author: Mladen Turk version: $Revision: 467222 $, $Date: 2006-10-24 05:17:11 +0200 (mar., 24 oct. 2006) $ |
Method Summary | |
native public static int | addrspaceSet(long attr, int addrspace) | native public static int | childErrSet(long attr, long err, long parent) Set the child_err and parent_err values to existing apr_file_t values.
This is NOT a required initializer function. | native public static int | childInSet(long attr, long in, long parent) Set the child_in and/or parent_in values to existing apr_file_t values.
This is NOT a required initializer function. | native public static int | childOutSet(long attr, long out, long parent) Set the child_out and parent_out values to existing apr_file_t values.
This is NOT a required initializer function. | native public static int | cmdtypeSet(long attr, int cmd) Set what type of command the child process will call.
Parameters: attr - The procattr we care about. Parameters: cmd - The type of command. | native public static long | create(long cont) | native public static int | detachSet(long attr, int detach) Determine if the child should start in detached state. | native public static int | dirSet(long attr, String dir) Set which directory the child process should start executing in.
Parameters: attr - The procattr we care about. Parameters: dir - Which dir to start in. | native public static void | errfnSet(long attr, long pool, Object o) Specify an error function to be called in the child process if APR
encounters an error in the child prior to running the specified program.
Parameters: attr - The procattr describing the child process to be created. Parameters: pool - The the pool to use. Parameters: o - The Object to call in the child process. At the present time, it will only be called from apr_proc_create()on platforms where fork() is used. | native public static int | errorCheckSet(long attr, int chk) Specify that apr_proc_create() should do whatever it can to report
failures to the caller of apr_proc_create(), rather than find out in
the child.
Parameters: attr - The procattr describing the child process to be created. Parameters: chk - Flag to indicate whether or not extra work should be doneto try to report failures to the caller. This flag only affects apr_proc_create() on platforms wherefork() is used. | native public static int | groupSet(long attr, String groupname) | native public static int | ioSet(long attr, int in, int out, int err) Determine if any of stdin, stdout, or stderr should be linked to pipes
when starting a child process. | native public static int | userSet(long attr, String username, String password) Set the username used for running process
Parameters: attr - The procattr we care about. Parameters: username - The username used Parameters: password - User password if needed. |
addrspaceSet | native public static int addrspaceSet(long attr, int addrspace)(Code) | | Determine if the child should start in its own address space or using the
current one from its parent
Parameters: attr - The procattr we care about. Parameters: addrspace - Should the child start in its own address space? Defaultis no on NetWare and yes on other platforms. |
childErrSet | native public static int childErrSet(long attr, long err, long parent)(Code) | | Set the child_err and parent_err values to existing apr_file_t values.
This is NOT a required initializer function. This is
useful if you have already opened a pipe (or multiple files)
that you wish to use, perhaps persistently across multiple
process invocations - such as a log file.
Parameters: attr - The procattr we care about. Parameters: err - apr_file_t value to use as child_err. Must be a valid file. Parameters: parent - apr_file_t value to use as parent_err. Must be a valid file. |
childInSet | native public static int childInSet(long attr, long in, long parent)(Code) | | Set the child_in and/or parent_in values to existing apr_file_t values.
This is NOT a required initializer function. This is
useful if you have already opened a pipe (or multiple files)
that you wish to use, perhaps persistently across multiple
process invocations - such as a log file. You can save some
extra function calls by not creating your own pipe since this
creates one in the process space for you.
Parameters: attr - The procattr we care about. Parameters: in - apr_file_t value to use as child_in. Must be a valid file. Parameters: parent - apr_file_t value to use as parent_in. Must be a valid file. |
childOutSet | native public static int childOutSet(long attr, long out, long parent)(Code) | | Set the child_out and parent_out values to existing apr_file_t values.
This is NOT a required initializer function. This is
useful if you have already opened a pipe (or multiple files)
that you wish to use, perhaps persistently across multiple
process invocations - such as a log file.
Parameters: attr - The procattr we care about. Parameters: out - apr_file_t value to use as child_out. Must be a valid file. Parameters: parent - apr_file_t value to use as parent_out. Must be a valid file. |
cmdtypeSet | native public static int cmdtypeSet(long attr, int cmd)(Code) | | Set what type of command the child process will call.
Parameters: attr - The procattr we care about. Parameters: cmd - The type of command. One of:APR_SHELLCMD -- Anything that the shell can handleAPR_PROGRAM -- Executable program (default)APR_PROGRAM_ENV -- Executable program, copy environmentAPR_PROGRAM_PATH -- Executable program on PATH, copy env |
create | native public static long create(long cont) throws Error(Code) | | Create and initialize a new procattr variable
Parameters: cont - The pool to use The newly created procattr. |
detachSet | native public static int detachSet(long attr, int detach)(Code) | | Determine if the child should start in detached state.
Parameters: attr - The procattr we care about. Parameters: detach - Should the child start in detached state? Default is no. |
dirSet | native public static int dirSet(long attr, String dir)(Code) | | Set which directory the child process should start executing in.
Parameters: attr - The procattr we care about. Parameters: dir - Which dir to start in. By default, this is the same dir asthe parent currently resides in, when the createprocess callis made. |
errfnSet | native public static void errfnSet(long attr, long pool, Object o)(Code) | | Specify an error function to be called in the child process if APR
encounters an error in the child prior to running the specified program.
Parameters: attr - The procattr describing the child process to be created. Parameters: pool - The the pool to use. Parameters: o - The Object to call in the child process. At the present time, it will only be called from apr_proc_create()on platforms where fork() is used. It will never be called on otherplatforms, on those platforms apr_proc_create() will return the errorin the parent process rather than invoke the callback in the now-forkedchild process. |
errorCheckSet | native public static int errorCheckSet(long attr, int chk)(Code) | | Specify that apr_proc_create() should do whatever it can to report
failures to the caller of apr_proc_create(), rather than find out in
the child.
Parameters: attr - The procattr describing the child process to be created. Parameters: chk - Flag to indicate whether or not extra work should be doneto try to report failures to the caller. This flag only affects apr_proc_create() on platforms wherefork() is used. This leads to extra overhead in the callingprocess, but that may help the application handle sucherrors more gracefully. |
groupSet | native public static int groupSet(long attr, String groupname)(Code) | | Set the group used for running process
Parameters: attr - The procattr we care about. Parameters: groupname - The group name used |
ioSet | native public static int ioSet(long attr, int in, int out, int err)(Code) | | Determine if any of stdin, stdout, or stderr should be linked to pipes
when starting a child process.
Parameters: attr - The procattr we care about. Parameters: in - Should stdin be a pipe back to the parent? Parameters: out - Should stdout be a pipe back to the parent? Parameters: err - Should stderr be a pipe back to the parent? |
userSet | native public static int userSet(long attr, String username, String password)(Code) | | Set the username used for running process
Parameters: attr - The procattr we care about. Parameters: username - The username used Parameters: password - User password if needed. Password is needed on WIN32or any other platform havingAPR_PROCATTR_USER_SET_REQUIRES_PASSWORD set. |
|
|