{
assertNotNull(refs);
int count = 1;
while (refs.hasNext())
{
MessageDestinationRefMetaData ref = refs.next();
String pref = prefix + "MessageDestinationRef" + count;
assertEquals(pref + "Name", ref.getRefName());
if (full)
{
assertEquals(pref + "Type", ref.getType());
if (count == 1)
assertEquals(MessageDestinationRefMetaData.CONSUMES, ref.getUsage());
else if (count == 2)
assertEquals(MessageDestinationRefMetaData.PRODUCES, ref.getUsage());
else
assertEquals(MessageDestinationRefMetaData.CONSUMESPRODUCES, ref.getUsage());
assertEquals(prefix + "MessageDestinationRef" + count + "Link", ref.getLink());
}
++count;
}
assertEquals(size + 1, count);
}