/** * Test that the JMSX property <code>JMSXGroupID</code> is supported. */ public void testSupportsJMSXGroupID() { try { boolean found = false; ConnectionMetaData metaData = senderConnection.getMetaData(); Enumeration enumeration = metaData.getJMSXPropertyNames(); while (enumeration.hasMoreElements()) { String jmsxPropertyName = (String) enumeration.nextElement(); if (jmsxPropertyName.equals("JMSXGroupID")) { found = true; } } assertTrue("JMSXGroupID property is not supported", found); } catch (JMSException e) { fail(e); } }
/** * Test that the JMSX property <code>JMSXDeliveryCount</code> is supported. */ public void testSupportsJMSXDeliveryCount() { try { boolean found = false; ConnectionMetaData metaData = senderConnection.getMetaData(); Enumeration enumeration = metaData.getJMSXPropertyNames(); while (enumeration.hasMoreElements()) { String jmsxPropertyName = (String) enumeration.nextElement(); if (jmsxPropertyName.equals("JMSXDeliveryCount")) { found = true; } } assertTrue("JMSXDeliveryCount property is not supported", found); } catch (JMSException e) { fail(e); } }
/** * checks if the JMSX property <code>JMSXDeliveryCount</code> is supported. */ private boolean supportsJMSXDeliveryCount() throws Exception { ConnectionMetaData metaData = senderConnection.getMetaData(); Enumeration enumeration = metaData.getJMSXPropertyNames(); while (enumeration.hasMoreElements()) { String jmsxPropertyName = (String) enumeration.nextElement(); if (jmsxPropertyName.equals("JMSXDeliveryCount")) { return true; } } return false; } }
/** * Test that the JMSX property <code>JMSXGroupID</code> is supported. */ @Test public void testSupportsJMSXGroupID() { try { boolean found = false; ConnectionMetaData metaData = senderConnection.getMetaData(); Enumeration enumeration = metaData.getJMSXPropertyNames(); while (enumeration.hasMoreElements()) { String jmsxPropertyName = (String) enumeration.nextElement(); if (jmsxPropertyName.equals("JMSXGroupID")) { found = true; } } Assert.assertTrue("JMSXGroupID property is not supported", found); } catch (JMSException e) { fail(e); } }