it.jnrpe
Class JNRPE

java.lang.Object
  extended by it.jnrpe.JNRPE

public final class JNRPE
extends Object

This class is the real JNRPE worker. It must be used to start listening for NRPE requests

Author:
Massimiliano Ziccardi

Constructor Summary
JNRPE(IPluginRepository pluginRepo, CommandRepository commandRepo)
          Deprecated. This constructor will be removed as of version 2.0.5. Use JNRPEBuilder instead
JNRPE(IPluginRepository pluginRepo, CommandRepository commandRepo, Charset newCharset, boolean acceptParameters)
          Deprecated. This constructor will be removed as of version 2.0.5. Use JNRPEBuilder instead
 
Method Summary
 void addAcceptedHost(String address)
          Deprecated. The JNRPE object will become immutable as of version 2.0.5. Use JNRPEBuilder instead
 void addEventListener(IJNRPEEventListener listener)
          Deprecated. The JNRPE object will become immutable as of version 2.0.5. Use JNRPEBuilder instead
 void listen(String address, int port)
          Instructs the server to listen to the given IP/port.
 void listen(String address, int port, boolean useSSL)
          Starts a new thread that listen for requests.
 void shutdown()
          Shuts down the server.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JNRPE

@Deprecated
public JNRPE(IPluginRepository pluginRepo,
                        CommandRepository commandRepo)
Deprecated. This constructor will be removed as of version 2.0.5. Use JNRPEBuilder instead

Instantiates the JNRPE engine.

Parameters:
pluginRepo - The plugin repository object
commandRepo - The command repository object

JNRPE

@Deprecated
public JNRPE(IPluginRepository pluginRepo,
                        CommandRepository commandRepo,
                        Charset newCharset,
                        boolean acceptParameters)
Deprecated. This constructor will be removed as of version 2.0.5. Use JNRPEBuilder instead

Initializes the JNRPE worker.

Parameters:
pluginRepo - The repository containing all the installed plugins
commandRepo - The repository containing all the configured commands.
newCharset - The charset that will be used by JNRPE
acceptParameters - Sets if $ARGxx$ macros should be expanded
Method Detail

listen

public void listen(String address,
                   int port)
            throws UnknownHostException
Instructs the server to listen to the given IP/port.

Parameters:
address - The address to bind to
port - The port to bind to
Throws:
UnknownHostException - -

addEventListener

@Deprecated
public void addEventListener(IJNRPEEventListener listener)
Deprecated. The JNRPE object will become immutable as of version 2.0.5. Use JNRPEBuilder instead

Adds a new event listener.

Parameters:
listener - The event listener to be added

listen

public void listen(String address,
                   int port,
                   boolean useSSL)
            throws UnknownHostException
Starts a new thread that listen for requests. The method is not blocking

Parameters:
address - The address to bind to
port - The listening port
useSSL - true if an SSL socket must be created.
Throws:
UnknownHostException - -

addAcceptedHost

@Deprecated
public void addAcceptedHost(String address)
Deprecated. The JNRPE object will become immutable as of version 2.0.5. Use JNRPEBuilder instead

Adds an address to the list of accepted hosts.

Parameters:
address - The address to accept

shutdown

public void shutdown()
Shuts down the server.



Copyright © 2014. All Rights Reserved.