/** * if the object passed in is equivalent, return true * * @param obj the object to compare * @return true if this instance and obj are equivalent */ public override bool Equals(Object obj) { bool result = this == obj; if (!result && obj != null && obj is ActiveMQDestination) { ActiveMQDestination other = (ActiveMQDestination)obj; result = this.GetDestinationType() == other.GetDestinationType() && this.physicalName.Equals(other.physicalName); } return(result); }
public static ActiveMQTopic GetDestinationAdvisoryTopic(ActiveMQDestination destination) { switch (destination.GetDestinationType()) { case ActiveMQDestination.ACTIVEMQ_QUEUE: return QUEUE_ADVISORY_TOPIC; case ActiveMQDestination.ACTIVEMQ_TOPIC: return TOPIC_ADVISORY_TOPIC; case ActiveMQDestination.ACTIVEMQ_TEMPORARY_QUEUE: return TEMP_QUEUE_ADVISORY_TOPIC; case ActiveMQDestination.ACTIVEMQ_TEMPORARY_TOPIC: return TEMP_TOPIC_ADVISORY_TOPIC; default: throw new NMSException("Unknown destination type: " + destination.DestinationType); } }