com.objectxp.mms
Interface MMSListener


public interface MMSListener

The MMSListener interface defines the methods required for processing incoming multimedia-messages, MMS notifications and read- and delivery reports. A MMSListener implementation can be registered with a MMSService using the MMSService.setListener(MMSListener) method.

Since:
jSMS 2.2

Method Summary
 MMSStatus handleDeliveryReport(MMSService service, MMSDeliveryReport report)
          Process an incomming Delivery Report.
 MMSStatus handleIncommingMessage(MMSService service, MMSMessage message)
          Process an incomming multimedia message.
 void handleNotification(MMSService service, MMSNotification notification)
          Process an incoming MMS notification.
 MMSStatus handleReadReport(MMSService service, MMSReadReport report)
          Process an incomming Read Report.
 

Method Detail

handleIncommingMessage

public MMSStatus handleIncommingMessage(MMSService service,
                                        MMSMessage message)
Process an incomming multimedia message. If processing is successful, implementations must return MMSStatus.SUCCESS. If the message cannot be processed or should be rejected, return one of the other MMSStatus constants. If the implementation returns null or throws a runtime exception, this is treated like returning MMSStatus.CLIENT_ERROR.

Parameters:
service - The calling service.
message - The incoming message to process
Returns:
The processing state.

handleReadReport

public MMSStatus handleReadReport(MMSService service,
                                  MMSReadReport report)
Process an incomming Read Report. If processing is successful, implementations must return MMSStatus.SUCCESS. If the report cannot be processed or should be rejected, return one of the other MMSStatus constants. If the implementation returns null or throws a runtime exception, this is treated like returning MMSStatus.CLIENT_ERROR.

Parameters:
service - The calling service.
report - The incoming Read Report.
Returns:
The processing state.

handleDeliveryReport

public MMSStatus handleDeliveryReport(MMSService service,
                                      MMSDeliveryReport report)
Process an incomming Delivery Report. If processing is successful, implementations must return MMSStatus.SUCCESS. If the report cannot be processed or should be rejected, return one of the other MMSStatus constants. If the implementation returns null or throws a runtime exception, this is treated like returning MMSStatus.CLIENT_ERROR.

Parameters:
service - The calling service.
report - The incoming Delivery Report
Returns:
The processing state.

handleNotification

public void handleNotification(MMSService service,
                               MMSNotification notification)
Process an incoming MMS notification. A notification cannot be rejected. Upon reception, the corresponding multi-media message can be fetched using MMSService.fetch(MMSNotification).

Parameters:
service - The calling service.
notification - the MMS notification.


object XP, Inc. © 2000-2007. All rights reserved object XP