MessageEndpoint endpoint = (MessageEndpoint) emailConsumer;
endpoint.beforeDelivery(EmailConsumer.class.getMethod("receiveEmail", Properties.class, String.class));
emailConsumer.receiveEmail(headers, body);
endpoint.afterDelivery();
}
}
public static class EmailAccountInfo implements ActivationSpec {
private EmailResourceAdapter emailResourceAdapter;