org.opennms.netmgt.config.poller
Class Downtime

java.lang.Object
  extended by org.opennms.netmgt.config.poller.Downtime
All Implemented Interfaces:
Serializable

public class Downtime
extends Object
implements Serializable

Downtime model. This determines the rates at which addresses are to be polled when they remain down for extended periods. Usually polling is done at lower rates when a node is down until a certain amount of downtime at which the node is marked 'deleted'.

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

Constructor Summary
Downtime()
           
 
Method Summary
 void deleteBegin()
           
 void deleteEnd()
           
 void deleteInterval()
           
 long getBegin()
          Returns the value of field 'begin'.
 String getDelete()
          Returns the value of field 'delete'.
 long getEnd()
          Returns the value of field 'end'.
 long getInterval()
          Returns the value of field 'interval'.
 boolean hasBegin()
          Method hasBegin.
 boolean hasEnd()
          Method hasEnd.
 boolean hasInterval()
          Method hasInterval.
 boolean isValid()
          Method isValid.
 void marshal(ContentHandler handler)
           
 void marshal(Writer out)
           
 void setBegin(long begin)
          Sets the value of field 'begin'.
 void setDelete(String delete)
          Sets the value of field 'delete'.
 void setEnd(long end)
          Sets the value of field 'end'.
 void setInterval(long interval)
          Sets the value of field 'interval'.
static Downtime 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

Downtime

public Downtime()
Method Detail

deleteBegin

public void deleteBegin()

deleteEnd

public void deleteEnd()

deleteInterval

public void deleteInterval()

getBegin

public long getBegin()
Returns the value of field 'begin'. The field 'begin' has the following description: Start of the interval.

Returns:
the value of field 'Begin'.

getDelete

public String getDelete()
Returns the value of field 'delete'. The field 'delete' has the following description: Attribute that determines if service is to be deleted when down continously until the start time.

Returns:
the value of field 'Delete'.

getEnd

public long getEnd()
Returns the value of field 'end'. The field 'end' has the following description: End of the interval.

Returns:
the value of field 'End'.

getInterval

public long getInterval()
Returns the value of field 'interval'. The field 'interval' has the following description: Interval at which service is to be polled between the specified start and end when service has been continously down.

Returns:
the value of field 'Interval'.

hasBegin

public boolean hasBegin()
Method hasBegin.

Returns:
true if at least one Begin has been added

hasEnd

public boolean hasEnd()
Method hasEnd.

Returns:
true if at least one End has been added

hasInterval

public boolean hasInterval()
Method hasInterval.

Returns:
true if at least one Interval has been added

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

setBegin

public void setBegin(long begin)
Sets the value of field 'begin'. The field 'begin' has the following description: Start of the interval.

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

setDelete

public void setDelete(String delete)
Sets the value of field 'delete'. The field 'delete' has the following description: Attribute that determines if service is to be deleted when down continously until the start time.

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

setEnd

public void setEnd(long end)
Sets the value of field 'end'. The field 'end' has the following description: End of the interval.

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

setInterval

public void setInterval(long interval)
Sets the value of field 'interval'. The field 'interval' has the following description: Interval at which service is to be polled between the specified start and end when service has been continously down.

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

unmarshal

public static Downtime 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.poller.Downtime
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.