org.apache.servicemix.jbi.nmr.flow.seda
Class SedaQueue

java.lang.Object
  extended by org.apache.servicemix.jbi.management.BaseLifeCycle
      extended by org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue
All Implemented Interfaces:
javax.jbi.management.LifeCycleMBean, MBeanInfoProvider

public class SedaQueue
extends BaseLifeCycle

A simple Straight through flow

Version:
$Revision: 564607 $

Field Summary
protected  org.apache.servicemix.executors.Executor executor
           
protected  SedaFlow flow
           
protected  ComponentNameSpace name
           
protected  ObjectName objectName
           
protected  AtomicBoolean running
           
protected  AtomicBoolean started
           
protected  String subType
           
protected  Thread thread
           
 
Fields inherited from class org.apache.servicemix.jbi.management.BaseLifeCycle
currentState, INITIALIZED, listener
 
Fields inherited from interface javax.jbi.management.LifeCycleMBean
SHUTDOWN, STARTED, STOPPED, UNKNOWN
 
Constructor Summary
SedaQueue(ComponentNameSpace name)
          SedaQueue name
 
Method Summary
 void enqueue(MessageExchangeImpl me)
          Enqueue a Packet for processing
 MBeanAttributeInfo[] getAttributeInfos()
          Get an array of MBeanAttributeInfo
 int getCapacity()
           
 ComponentNameSpace getComponentNameSpace()
           
 String getDescription()
          Get the description
 String getName()
          Get the name
 ObjectName getObjectName()
           
 int getSize()
           
 String getType()
          Get the type of the item
 void init(SedaFlow seda)
          Initialize the Region
 void setObjectName(ObjectName objectName)
           
 void shutDown()
          shutDown the Queue
 void start()
          start processing
 void stop()
          stop processing
 String toString()
           
 
Methods inherited from class org.apache.servicemix.jbi.management.BaseLifeCycle
firePropertyChanged, getCurrentState, getObjectToManage, getOperationInfos, getSubType, init, isInitialized, isShutDown, isStarted, isStopped, isUnknown, setCurrentState, setPropertyChangeListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

flow

protected SedaFlow flow

name

protected ComponentNameSpace name

started

protected AtomicBoolean started

running

protected AtomicBoolean running

objectName

protected ObjectName objectName

subType

protected String subType

thread

protected Thread thread

executor

protected org.apache.servicemix.executors.Executor executor
Constructor Detail

SedaQueue

public SedaQueue(ComponentNameSpace name)
SedaQueue name

Parameters:
name -
Method Detail

getName

public String getName()
Get the name

Specified by:
getName in interface MBeanInfoProvider
Overrides:
getName in class BaseLifeCycle
Returns:
name

getType

public String getType()
Description copied from class: BaseLifeCycle
Get the type of the item

Specified by:
getType in interface MBeanInfoProvider
Overrides:
getType in class BaseLifeCycle
Returns:
the type

getComponentNameSpace

public ComponentNameSpace getComponentNameSpace()
Returns:
Return the name

getDescription

public String getDescription()
Get the description

Returns:
description

init

public void init(SedaFlow seda)
Initialize the Region

Parameters:
seda -

getCapacity

public int getCapacity()
Returns:
the capacity of the Queue

getSize

public int getSize()
Returns:
size of the Queue

enqueue

public void enqueue(MessageExchangeImpl me)
             throws InterruptedException,
                    javax.jbi.messaging.MessagingException
Enqueue a Packet for processing

Parameters:
packet -
Throws:
InterruptedException
javax.jbi.messaging.MessagingException

start

public void start()
           throws javax.jbi.JBIException
start processing

Specified by:
start in interface javax.jbi.management.LifeCycleMBean
Overrides:
start in class BaseLifeCycle
Throws:
javax.jbi.JBIException

stop

public void stop()
          throws javax.jbi.JBIException
stop processing

Specified by:
stop in interface javax.jbi.management.LifeCycleMBean
Overrides:
stop in class BaseLifeCycle
Throws:
javax.jbi.JBIException

shutDown

public void shutDown()
              throws javax.jbi.JBIException
shutDown the Queue

Specified by:
shutDown in interface javax.jbi.management.LifeCycleMBean
Overrides:
shutDown in class BaseLifeCycle
Throws:
javax.jbi.JBIException

toString

public String toString()
Overrides:
toString in class Object
Returns:
pretty print

getAttributeInfos

public MBeanAttributeInfo[] getAttributeInfos()
                                       throws JMException
Get an array of MBeanAttributeInfo

Specified by:
getAttributeInfos in interface MBeanInfoProvider
Overrides:
getAttributeInfos in class BaseLifeCycle
Returns:
array of AttributeInfos
Throws:
JMException

getObjectName

public ObjectName getObjectName()
Returns:
Returns the objectName.

setObjectName

public void setObjectName(ObjectName objectName)
Parameters:
objectName - The objectName to set.


Copyright © 2005-2008 Apache Software Foundation. All Rights Reserved.