org.openmms.ejb.server
Interface MM2Storage

All Superinterfaces:
javax.ejb.EJBObject, java.rmi.Remote

public interface MM2Storage
extends javax.ejb.EJBObject

Title: MM2Storage

Description: This class provides an interface for storing an MM

Copyright: Copyright (c) 2003 OpenMMS.org


Method Summary
 boolean deleteMM(java.lang.String ID)
          Interface for deleting an MM from storage
 MM_Data fetchMM(java.lang.String ID, MM_Data mm)
          Interface for fetching the MM from storage
 boolean storeMM(java.lang.String ID, MM_Data mm, java.lang.String expiry, java.lang.String deliveryTime, java.lang.String deliveryReportValue, java.lang.String readReportValue)
          An interface for storing an MM
 boolean updateMM(java.lang.String ID, MM_Data mm, java.lang.String expiry, java.lang.String deliveryTime, java.lang.String deliveryReportValue, java.lang.String readReportValue)
          Interface for updating the status of an MM
 
Methods inherited from interface javax.ejb.EJBObject
getEJBHome, getHandle, getPrimaryKey, isIdentical, remove
 

Method Detail

storeMM

public boolean storeMM(java.lang.String ID,
                       MM_Data mm,
                       java.lang.String expiry,
                       java.lang.String deliveryTime,
                       java.lang.String deliveryReportValue,
                       java.lang.String readReportValue)
                throws java.rmi.RemoteException,
                       OpenMMSException
An interface for storing an MM

Parameters:
ID - - unique ID for the MM
mm - - MM_data object containing the message
expiry - - the message expiry date
deliveryTime - - the earliest delivery time for the MM
deliveryReportValue - - the value of the permit delivery report YES/NO
readReportValue - - the value of the permit read report YES/NO
Returns:
true if MM is stored, otherwise false
Throws:
java.rmi.RemoteException - - if communication with the server fails at some point
OpenMMSException - - for other types of error

fetchMM

public MM_Data fetchMM(java.lang.String ID,
                       MM_Data mm)
                throws java.rmi.RemoteException,
                       OpenMMSException
Interface for fetching the MM from storage

Parameters:
ID - - unique ID for the MM
mm - - MM_Data object containing the MM
Returns:
true if MM is fetched ok, otherwise false
Throws:
java.rmi.RemoteException
OpenMMSException

updateMM

public boolean updateMM(java.lang.String ID,
                        MM_Data mm,
                        java.lang.String expiry,
                        java.lang.String deliveryTime,
                        java.lang.String deliveryReportValue,
                        java.lang.String readReportValue)
                 throws java.rmi.RemoteException,
                        OpenMMSException
Interface for updating the status of an MM

Parameters:
ID -
mm -
expiry -
deliveryTime -
deliveryReportValue -
readReportValue -
Returns:
true if update is successful, otherwise false
Throws:
java.rmi.RemoteException
OpenMMSException

deleteMM

public boolean deleteMM(java.lang.String ID)
                 throws java.rmi.RemoteException,
                        OpenMMSException
Interface for deleting an MM from storage

Parameters:
ID -
Returns:
true if MM is deleted, otherwise false
Throws:
java.rmi.RemoteException
OpenMMSException