|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.tools.ant.ProjectComponent
org.apache.tools.ant.Task
org.apache.commons.messenger.task.ConsumerTask
ConsumerTask
is an Ant task which will
publish all of the given text files as a JMS Text Message
using a given JMS Connection (Messenger) and a Destination
Field Summary | |
private int |
count
the number of messages to receive |
private javax.jms.Destination |
destination
|
private java.io.File |
dir
the output directory |
private Messenger |
messenger
|
private MessengerManager |
messengerManager
|
private java.lang.String |
messengerName
|
private java.lang.String |
subject
|
Fields inherited from class org.apache.tools.ant.Task |
target, taskName, taskType, wrapper |
Fields inherited from class org.apache.tools.ant.ProjectComponent |
description, location, project |
Constructor Summary | |
ConsumerTask()
|
Method Summary | |
void |
execute()
Performs the copy operation. |
int |
getCount()
|
javax.jms.Destination |
getDestination()
Getter for property destination. |
Messenger |
getMessenger()
|
MessengerManager |
getMessengerManager()
Getter for property messengerManager. |
java.lang.String |
getMessengerName()
Getter for property messengerName. |
java.lang.String |
getSubject()
Getter for property subject. |
protected void |
processMessage(javax.jms.Message message)
Processes a given message |
protected void |
processMessageText(java.lang.String text)
Writes the given text to a file |
void |
setConfiguration(java.lang.String uri)
Sets the URI of the Messenger.xml configuration document to use to configure the messengers to use for this task. |
void |
setCount(int count)
Setter for the number of messages to receive. |
void |
setDestination(javax.jms.Destination destination)
Setter for property destination. |
void |
setDir(java.io.File dir)
Sets the output directory |
void |
setMessenger(Messenger messenger)
Sets the Messenger to be used |
void |
setMessengerManager(MessengerManager messengerManager)
Setter for property messengerManager. |
void |
setMessengerName(java.lang.String messengerName)
Setter for property messengerName. |
void |
setSubject(java.lang.String subject)
Setter for property subject. |
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 |
Methods inherited from class org.apache.tools.ant.ProjectComponent |
clone, getDescription, getLocation, getProject, setDescription, setLocation, setProject |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private Messenger messenger
private java.lang.String messengerName
private javax.jms.Destination destination
private java.lang.String subject
private MessengerManager messengerManager
private int count
private java.io.File dir
Constructor Detail |
public ConsumerTask()
Method Detail |
public void setDir(java.io.File dir)
public Messenger getMessenger() throws javax.jms.JMSException
javax.jms.JMSException
public void setMessenger(Messenger messenger)
public java.lang.String getMessengerName()
public void setMessengerName(java.lang.String messengerName)
messengerName
- New value of property messengerName.public javax.jms.Destination getDestination() throws javax.jms.JMSException
javax.jms.JMSException
public void setDestination(javax.jms.Destination destination)
destination
- New value of property destination.public java.lang.String getSubject()
public void setSubject(java.lang.String subject)
subject
- New value of property subject.public MessengerManager getMessengerManager()
public void setMessengerManager(MessengerManager messengerManager)
messengerManager
- New value of property messengerManager.public void setConfiguration(java.lang.String uri) throws javax.jms.JMSException
javax.jms.JMSException
public int getCount()
public void setCount(int count)
public void execute() throws org.apache.tools.ant.BuildException
org.apache.tools.ant.BuildException
protected void processMessage(javax.jms.Message message) throws java.io.IOException, javax.jms.JMSException
java.io.IOException
javax.jms.JMSException
protected void processMessageText(java.lang.String text) throws java.io.IOException
java.io.IOException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |