Class AddNetworkRouteTask
- java.lang.Object
-
- org.apache.tools.ant.ProjectComponent
-
- org.apache.tools.ant.Task
-
- com.opencloud.sipservlet.client.ant.SipServletTask
-
- com.opencloud.sipservlet.client.ant.AddNetworkRouteTask
-
- All Implemented Interfaces:
java.lang.Cloneable
public class AddNetworkRouteTask extends SipServletTask
Adds a network route to a SIP Servlet RA entity. This task invokes theNetworkInterfaceManagementMXBean.addRoute(String, String, int)
management operation.Ant Parameters
Attribute Description Required rule The rule to match for this route to be selected. Yes. interface The name of the network interface to be used if this route is selected. Yes. position The position in the current route list in which to add this new one. - Values less than zero will be treated as zero, ie. insert at the beginning of the list.
- Values greater than the current number of routes will be treated as equal to the current number of routes, ie. insert at the end of the list.
No. Default is to add to the end of the list. connectionrefid The id of a previous connect
task that will be used to connect to a SIP Servlet RA entity.No. The connection from the last successful connect
task is used by default.failonerror Default failure case behaviour for this task. If set to 'false' or 'no', the build will continue when this task attempts a redundant action. No. Default is false
.Example
<addnetworkroute rule="ip 192.168.0.0/24" interface="internal"/>
-
-
Constructor Summary
Constructors Constructor Description AddNetworkRouteTask()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
execute(SipServletClient client)
void
setInterface(java.lang.String interfaceName)
void
setPosition(int pos)
void
setRule(java.lang.String rule)
protected void
validateParameters()
-
Methods inherited from class com.opencloud.sipservlet.client.ant.SipServletTask
debug, debug, error, error, execute, fatal, fatal, fatal, getFailOnError, getSipServletClient, info, info, nonFatal, nonFatal, nonFatal, setConnectionRefId, setFailOnError, toByteArray, toString, verbose, verbose, warn, warn
-
Methods inherited from class org.apache.tools.ant.Task
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType
-
-
-
-
Method Detail
-
setRule
public void setRule(java.lang.String rule)
-
setInterface
public void setInterface(java.lang.String interfaceName)
-
setPosition
public void setPosition(int pos)
-
validateParameters
protected void validateParameters() throws org.apache.tools.ant.BuildException
- Specified by:
validateParameters
in classSipServletTask
- Throws:
org.apache.tools.ant.BuildException
-
execute
protected void execute(SipServletClient client)
- Specified by:
execute
in classSipServletTask
-
-