Hammered out some compiler warnings

This commit is contained in:
Iwein Fuld
2009-03-23 16:14:05 +00:00
parent 6bd4daf632
commit 51142a0cd9
15 changed files with 20 additions and 21 deletions

View File

@@ -63,13 +63,14 @@ public class JmsDestinationPollingSource extends AbstractJmsTemplateBasedAdapter
this.extractPayload = extractPayload;
}
@SuppressWarnings("unchecked")
public Message<Object> receive() {
Object receivedObject = this.getJmsTemplate().receiveAndConvert();
if (receivedObject == null) {
return null;
}
if (receivedObject instanceof Message) {
return (Message<Object>) receivedObject;
return (Message) receivedObject;
}
return new GenericMessage<Object>(receivedObject);
}