Package org.apache.activemq.command
Class ConsumerControl
- java.lang.Object
-
- org.apache.activemq.command.BaseCommand
-
- org.apache.activemq.command.ConsumerControl
-
- All Implemented Interfaces:
Command,DataStructure
public class ConsumerControl extends BaseCommand
Used to start and stop transports as well as terminating clients.
-
-
Field Summary
Fields Modifier and Type Field Description protected booleancloseprotected ConsumerIdconsumerIdstatic byteDATA_STRUCTURE_TYPEprotected ActiveMQDestinationdestinationprotected booleanflushprotected intprefetchprotected booleanstartprotected booleanstop-
Fields inherited from class org.apache.activemq.command.BaseCommand
commandId, responseRequired
-
-
Constructor Summary
Constructors Constructor Description ConsumerControl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ConsumerIdgetConsumerId()bytegetDataStructureType()ActiveMQDestinationgetDestination()intgetPrefetch()booleanisClose()booleanisConsumerControl()booleanisFlush()booleanisStart()booleanisStop()voidsetClose(boolean close)voidsetConsumerId(ConsumerId consumerId)voidsetDestination(ActiveMQDestination destination)voidsetFlush(boolean flush)voidsetPrefetch(int prefetch)voidsetStart(boolean start)voidsetStop(boolean stop)Responsevisit(CommandVisitor visitor)-
Methods inherited from class org.apache.activemq.command.BaseCommand
copy, getCommandId, getFrom, getTo, isBrokerInfo, isConnectionControl, isMarshallAware, isMessage, isMessageAck, isMessageDispatch, isMessageDispatchNotification, isResponse, isResponseRequired, isShutdownInfo, isWireFormatInfo, setCommandId, setFrom, setResponseRequired, setTo, toString, toString
-
-
-
-
Field Detail
-
DATA_STRUCTURE_TYPE
public static final byte DATA_STRUCTURE_TYPE
- See Also:
- Constant Field Values
-
consumerId
protected ConsumerId consumerId
-
close
protected boolean close
-
stop
protected boolean stop
-
start
protected boolean start
-
flush
protected boolean flush
-
prefetch
protected int prefetch
-
destination
protected ActiveMQDestination destination
-
-
Method Detail
-
getDestination
public ActiveMQDestination getDestination()
- Returns:
- Returns the destination.
-
setDestination
public void setDestination(ActiveMQDestination destination)
-
getDataStructureType
public byte getDataStructureType()
- Returns:
- The type of the data structure
-
visit
public Response visit(CommandVisitor visitor) throws Exception
- Throws:
Exception
-
isConsumerControl
public boolean isConsumerControl()
- Specified by:
isConsumerControlin interfaceCommand- Overrides:
isConsumerControlin classBaseCommand
-
isClose
public boolean isClose()
- Returns:
- Returns the close.
-
setClose
public void setClose(boolean close)
- Parameters:
close- The new value to assign the close state flag.
-
getConsumerId
public ConsumerId getConsumerId()
- Returns:
- Returns the consumerId.
-
setConsumerId
public void setConsumerId(ConsumerId consumerId)
- Parameters:
consumerId- The consumerId to set.
-
getPrefetch
public int getPrefetch()
- Returns:
- Returns the prefetch.
-
setPrefetch
public void setPrefetch(int prefetch)
- Parameters:
prefetch- The prefetch to set.
-
isFlush
public boolean isFlush()
- Returns:
- the flush
-
setFlush
public void setFlush(boolean flush)
- Parameters:
flush- The flush value to set on this command.
-
isStart
public boolean isStart()
- Returns:
- the start
-
setStart
public void setStart(boolean start)
- Parameters:
start- The start value to set on this command.
-
isStop
public boolean isStop()
- Returns:
- the stop
-
setStop
public void setStop(boolean stop)
- Parameters:
stop- the stop value to set on this Command.
-
-