org.opennms.netmgt.config.syslogd
Class Configuration

java.lang.Object
  extended by org.opennms.netmgt.config.syslogd.Configuration
All Implemented Interfaces:
Serializable

public class Configuration
extends Object
implements Serializable

Top-level element for the syslogd-configuration.xml configuration file.

Version:
$Revision$ $Date$
See Also:
Serialized Form

Constructor Summary
Configuration()
           
 
Method Summary
 void deleteMatchingGroupHost()
           
 void deleteMatchingGroupMessage()
           
 void deleteNewSuspectOnMessage()
           
 void deleteSyslogPort()
           
 String getForwardingRegexp()
          Returns the value of field 'forwardingRegexp'.
 int getMatchingGroupHost()
          Returns the value of field 'matchingGroupHost'.
 int getMatchingGroupMessage()
          Returns the value of field 'matchingGroupMessage'.
 boolean getNewSuspectOnMessage()
          Returns the value of field 'newSuspectOnMessage'.
 int getSyslogPort()
          Returns the value of field 'syslogPort'.
 boolean hasMatchingGroupHost()
          Method hasMatchingGroupHost.
 boolean hasMatchingGroupMessage()
          Method hasMatchingGroupMessage.
 boolean hasNewSuspectOnMessage()
          Method hasNewSuspectOnMessage.
 boolean hasSyslogPort()
          Method hasSyslogPort.
 boolean isNewSuspectOnMessage()
          Returns the value of field 'newSuspectOnMessage'.
 boolean isValid()
          Method isValid.
 void marshal(ContentHandler handler)
           
 void marshal(Writer out)
           
 void setForwardingRegexp(String forwardingRegexp)
          Sets the value of field 'forwardingRegexp'.
 void setMatchingGroupHost(int matchingGroupHost)
          Sets the value of field 'matchingGroupHost'.
 void setMatchingGroupMessage(int matchingGroupMessage)
          Sets the value of field 'matchingGroupMessage'.
 void setNewSuspectOnMessage(boolean newSuspectOnMessage)
          Sets the value of field 'newSuspectOnMessage'.
 void setSyslogPort(int syslogPort)
          Sets the value of field 'syslogPort'.
static Configuration unmarshal(Reader reader)
          Method unmarshal.
 void validate()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Configuration

public Configuration()
Method Detail

deleteMatchingGroupHost

public void deleteMatchingGroupHost()

deleteMatchingGroupMessage

public void deleteMatchingGroupMessage()

deleteNewSuspectOnMessage

public void deleteNewSuspectOnMessage()

deleteSyslogPort

public void deleteSyslogPort()

getForwardingRegexp

public String getForwardingRegexp()
Returns the value of field 'forwardingRegexp'. The field 'forwardingRegexp' has the following description: The regular expression used to separate message and host.

Returns:
the value of field 'ForwardingRegexp'.

getMatchingGroupHost

public int getMatchingGroupHost()
Returns the value of field 'matchingGroupHost'. The field 'matchingGroupHost' has the following description: The matching group for the host

Returns:
the value of field 'MatchingGroupHost'.

getMatchingGroupMessage

public int getMatchingGroupMessage()
Returns the value of field 'matchingGroupMessage'. The field 'matchingGroupMessage' has the following description: The matching group for the message

Returns:
the value of field 'MatchingGroupMessage'.

getNewSuspectOnMessage

public boolean getNewSuspectOnMessage()
Returns the value of field 'newSuspectOnMessage'. The field 'newSuspectOnMessage' has the following description: Whether messages from devices unknown to OpenNMS should generate newSuspect events.

Returns:
the value of field 'NewSuspectOnMessage'.

getSyslogPort

public int getSyslogPort()
Returns the value of field 'syslogPort'. The field 'syslogPort' has the following description: The port on which Syslogd listens for SYSLOG Messages. The standard port is 514.

Returns:
the value of field 'SyslogPort'.

hasMatchingGroupHost

public boolean hasMatchingGroupHost()
Method hasMatchingGroupHost.

Returns:
true if at least one MatchingGroupHost has been added

hasMatchingGroupMessage

public boolean hasMatchingGroupMessage()
Method hasMatchingGroupMessage.

Returns:
true if at least one MatchingGroupMessage has been added

hasNewSuspectOnMessage

public boolean hasNewSuspectOnMessage()
Method hasNewSuspectOnMessage.

Returns:
true if at least one NewSuspectOnMessage has been added

hasSyslogPort

public boolean hasSyslogPort()
Method hasSyslogPort.

Returns:
true if at least one SyslogPort has been added

isNewSuspectOnMessage

public boolean isNewSuspectOnMessage()
Returns the value of field 'newSuspectOnMessage'. The field 'newSuspectOnMessage' has the following description: Whether messages from devices unknown to OpenNMS should generate newSuspect events.

Returns:
the value of field 'NewSuspectOnMessage'.

isValid

public boolean isValid()
Method isValid.

Returns:
true if this object is valid according to the schema

marshal

public void marshal(Writer out)
             throws org.exolab.castor.xml.MarshalException,
                    org.exolab.castor.xml.ValidationException
Parameters:
out -
Throws:
org.exolab.castor.xml.MarshalException - if object is null or if any SAXException is thrown during marshaling
org.exolab.castor.xml.ValidationException - if this object is an invalid instance according to the schema

marshal

public void marshal(ContentHandler handler)
             throws IOException,
                    org.exolab.castor.xml.MarshalException,
                    org.exolab.castor.xml.ValidationException
Parameters:
handler -
Throws:
IOException - if an IOException occurs during marshaling
org.exolab.castor.xml.ValidationException - if this object is an invalid instance according to the schema
org.exolab.castor.xml.MarshalException - if object is null or if any SAXException is thrown during marshaling

setForwardingRegexp

public void setForwardingRegexp(String forwardingRegexp)
Sets the value of field 'forwardingRegexp'. The field 'forwardingRegexp' has the following description: The regular expression used to separate message and host.

Parameters:
forwardingRegexp - the value of field 'forwardingRegexp'

setMatchingGroupHost

public void setMatchingGroupHost(int matchingGroupHost)
Sets the value of field 'matchingGroupHost'. The field 'matchingGroupHost' has the following description: The matching group for the host

Parameters:
matchingGroupHost - the value of field 'matchingGroupHost'.

setMatchingGroupMessage

public void setMatchingGroupMessage(int matchingGroupMessage)
Sets the value of field 'matchingGroupMessage'. The field 'matchingGroupMessage' has the following description: The matching group for the message

Parameters:
matchingGroupMessage - the value of field 'matchingGroupMessage'.

setNewSuspectOnMessage

public void setNewSuspectOnMessage(boolean newSuspectOnMessage)
Sets the value of field 'newSuspectOnMessage'. The field 'newSuspectOnMessage' has the following description: Whether messages from devices unknown to OpenNMS should generate newSuspect events.

Parameters:
newSuspectOnMessage - the value of field 'newSuspectOnMessage'.

setSyslogPort

public void setSyslogPort(int syslogPort)
Sets the value of field 'syslogPort'. The field 'syslogPort' has the following description: The port on which Syslogd listens for SYSLOG Messages. The standard port is 514.

Parameters:
syslogPort - the value of field 'syslogPort'.

unmarshal

public static Configuration unmarshal(Reader reader)
                               throws org.exolab.castor.xml.MarshalException,
                                      org.exolab.castor.xml.ValidationException
Method unmarshal.

Parameters:
reader -
Returns:
the unmarshaled org.opennms.netmgt.config.syslogd.Configuration
Throws:
org.exolab.castor.xml.MarshalException - if object is null or if any SAXException is thrown during marshaling
org.exolab.castor.xml.ValidationException - if this object is an invalid instance according to the schema

validate

public void validate()
              throws org.exolab.castor.xml.ValidationException
Throws:
org.exolab.castor.xml.ValidationException - if this object is an invalid instance according to the schema


Copyright ? 2008. All Rights Reserved.