Package org.activemq.advisories

Examples of org.activemq.advisories.TempDestinationAdvisor


      throws JMSException {
    if (d != null) {
      ActiveMQDestination dest = (ActiveMQDestination) ActiveMQMessageTransformation
          .transformDestination(d);
      if (dest.isTemporary()) {
        TempDestinationAdvisor test = (TempDestinationAdvisor) validDestinationsMap
            .get(dest);
        if (test == null) {
          test = new TempDestinationAdvisor(this, dest);
          test.start();
          validDestinationsMap.put(dest, test);
        }
      }
    }
  }
View Full Code Here


      throws JMSException {
    if (d != null) {
      ActiveMQDestination dest = (ActiveMQDestination) ActiveMQMessageTransformation
          .transformDestination(d);
      if (dest.isTemporary()) {
        TempDestinationAdvisor test = (TempDestinationAdvisor) validDestinationsMap
            .remove(dest);
        if (test != null) {
          test.stop();
        }
      }
    }
  }
View Full Code Here

   
    protected void startAdvisoryForTempDestination(Destination d) throws JMSException {
        if (d != null) {
            ActiveMQDestination dest = (ActiveMQDestination) ActiveMQMessageTransformation.transformDestination(d);
            if (dest.isTemporary()) {
                TempDestinationAdvisor test = (TempDestinationAdvisor) validDestinationsMap.get(dest);
                if (test == null) {
                    test = new TempDestinationAdvisor(this, dest);
                    test.start();
                    validDestinationsMap.put(dest, test);
                }
            }
        }
    }
View Full Code Here

   
    protected void stopAdvisoryForTempDestination(ActiveMQDestination d) throws JMSException {
        if (d != null) {
            ActiveMQDestination dest = (ActiveMQDestination) ActiveMQMessageTransformation.transformDestination(d);
            if (dest.isTemporary()) {
                TempDestinationAdvisor test = (TempDestinationAdvisor) validDestinationsMap.remove(dest);
                if (test != null) {
                    test.stop();
                }
            }
        }
    }
View Full Code Here

    }
   
    protected final void validateDestination(ActiveMQDestination dest) throws JMSException{
        if (dest != null){
            if (dest.isTemporary()){
                TempDestinationAdvisor test = (TempDestinationAdvisor) validDestinationsMap.get(dest);
                if (dest.isDeleted() || test ==null || !test.isActive(dest)){
                    throw new JMSException("Cannot publish to a deleted Destination: " + dest);
                }
            }
        }
    }
View Full Code Here

TOP

Related Classes of org.activemq.advisories.TempDestinationAdvisor

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.