public interface IServiceBuilder
Modifier and Type | Method and Description |
---|---|
String[] |
arguments()
Returns the arguments to be passed to the native process.
|
IServiceBuilder |
arguments(String[] args)
Sets the arguments to be passed to the native process.
|
String |
command()
Returns the native executable to launch.
|
IServiceBuilder |
command(File command)
Sets the native executable to launch.
|
IServiceBuilder |
command(String command)
Sets the native executable to launch.
|
int |
connectionsPerProcess()
Returns the number of connections established per process.
|
IServiceBuilder |
connectionsPerProcess(int connectionsPerProcess)
Sets the number of connections established per process.
|
INativeService |
create()
Creates and returns an INativeService object.
|
int |
debugPort()
Returns TCP port to listen on for debug connection.
|
IServiceBuilder |
debugPort(int port)
Sets the TCP port to listen on for debug connection.
|
File |
directory()
Returns the working directory of the native process.
|
IServiceBuilder |
directory(File directory)
Sets the working directory of the native process.
|
Map<String,String> |
environment()
Returns a rereference to this ServiceBuilders environment map.
|
String |
id()
Returns the unique id of the NativeService.
|
IServiceBuilder |
id(String id)
Sets the unique id of the NativeService.
|
int |
launchTimeout()
Maximum time to wait for a spawned child process' connection.
|
IServiceBuilder |
launchTimeout(int timeout)
Sets the maximum time to wait for a spawned child process' connection.
|
String |
library()
Returns the path of the NativeService library to load.
|
IServiceBuilder |
library(File library)
Sets the path of the NativeService library to load.
|
IServiceBuilder |
library(String library)
Sets the path of the NativeService library to load.
|
File |
logDir()
Returns the service log directory.
|
IServiceBuilder |
logDir(File logdir)
Sets the service log directory.
|
String |
loggerName()
Returns the Logger name (i.e.
|
IServiceBuilder |
loggerName(String loggerName)
Logger name (i.e.
|
int |
maxConnections()
Returns the maximum connection pool size
|
IServiceBuilder |
maxConnections(int maxConnections)
Sets the maximum connection pool size
|
int |
maxRequests()
Returns the maximum number of requests per process.
|
IServiceBuilder |
maxRequests(int maxRequests)
Sets the maximum number of requests per process.
|
IProcessLauncherHook |
processLauncherHook()
Returns the
IProcessLauncherHook . |
IServiceBuilder |
processLauncherHook(IProcessLauncherHook hook)
Set the
IProcessLauncherHook instance or null. |
int |
terminationTimeout()
Maximum time to wait for a spawned child process' graceful termination.
|
IServiceBuilder |
terminationTimeout(int timeout)
Sets the maximum time to wait for a spawned child process' graceful
termination.
|
File |
tmpDir()
Returns the service temp directory.
|
IServiceBuilder |
tmpDir(File tmpDir)
Sets the service temp directory.
|
INativeService create() throws NativeCommException
NativeCommException
- on failureString id()
IServiceBuilder id(String id)
id
- unique id to setint maxConnections()
IServiceBuilder maxConnections(int maxConnections)
maxConnections
- maximum connection pool sizeint maxRequests()
IServiceBuilder maxRequests(int maxRequests)
maxRequests
- maximum number of requests per process (0 == unlimited)String[] arguments()
IServiceBuilder arguments(String[] args)
args
- to be passed to the native processMap<String,String> environment()
String library()
IServiceBuilder library(String library)
library
- path of the NativeService library to loadIServiceBuilder library(File library)
library
- path of the NativeService library to loadFile directory()
IServiceBuilder directory(File directory)
directory
- working directory of the native process; if null, the parent
directory of the library is usedString command()
IServiceBuilder command(String command)
command
- native executable to launch; if null, the default NativeComm
host is usedIServiceBuilder command(File command)
command
- native executable to launch; if null, the default NativeComm
host is usedint connectionsPerProcess()
IServiceBuilder connectionsPerProcess(int connectionsPerProcess)
connectionsPerProcess
- number of connections established per processFile logDir()
IServiceBuilder logDir(File logdir)
logdir
- the service log directory; if null the working directory is usedFile tmpDir()
IServiceBuilder tmpDir(File tmpDir)
tmpDir
- the service temp directory; if null the default temp path is inheritedint launchTimeout()
IServiceBuilder launchTimeout(int timeout)
timeout
- maximum time to wait for a spawned child process' connection.launchTimeout()
int terminationTimeout()
IServiceBuilder terminationTimeout(int timeout)
timeout
- maximum time to wait for a spawned child process' graceful termination.terminationTimeout()
int debugPort()
IServiceBuilder debugPort(int port)
port
- TCP port to listen on for debug connection; 0 if not debuggingIServiceBuilder loggerName(String loggerName)
loggerName
- - logger name (i.e. class name of NComm service user).String loggerName()
IProcessLauncherHook processLauncherHook()
IProcessLauncherHook
.IProcessLauncherHook
.IServiceBuilder processLauncherHook(IProcessLauncherHook hook)
IProcessLauncherHook
instance or null.hook
- - IProcessLauncherHook
instance or null.Copyright © 2010 - 2020 Adobe. All Rights Reserved