public class MfMailSTUpdateHandler extends java.lang.Object implements ActionCustomClass
| Constructor and Description |
|---|
MfMailSTUpdateHandler() |
| Modifier and Type | Method and Description |
|---|---|
protected java.util.Date |
adjustToServerTimeZone(java.util.Date srcDate,
UserInfo ui)
Method to convert time between user timezone and server timezone
|
void |
applyCustomAction(MboRemote inboundComm,
java.lang.Object[] arg1)
(non-Javadoc)
|
protected java.lang.String |
checkAttributes(java.util.Hashtable values,
java.util.HashSet keySet,
boolean bMedium,
MfMailSTCtrlInfo ctrlInfo)
Check if all the attributes in values hashset are valid.
|
protected java.util.Date |
getChangeTime(java.util.Date sendDate,
java.lang.String timeStr,
MboRemote trackEntry,
UserInfo ui)
Method to calculate change time from time in HHMM format
|
protected MfMailSTCtrlInfo |
getControlEntry(java.lang.String MboName,
java.lang.String status,
UserInfo ui) |
protected MfMailSTCtrlInfo |
getNextStatus(MfMailSTMailInfo mi,
MboRemote trackEntry,
UserInfo ui,
MfMailSTCtrlInfo ci)
Get desired new status from current status and status value
|
protected java.lang.String |
getQueryString(java.lang.String subject,
MfMailSTMailInfo mi)
Create query string to retrieve targetMbo from subject line for small device
|
protected MboRemote |
getReplyTemplate(java.lang.String replyTemplateName,
UserInfo ui,
MboRemote trackEntry,
MboRemote target,
boolean checkHtml,
boolean bRequired)
Get communication template for reply.
|
protected MboRemote |
getTrackEntry(MboRemote targetMbo,
java.lang.String MboName,
java.lang.String secStr) |
protected void |
handleMAXIMOMAILMessageForVerySmall(MboRemote inboundComm,
UserInfo ui,
MfMailSTMailInfo miOrig) |
protected void |
handleMAXIMOMAILMessageWithNVPair(MboRemote inboundComm,
UserInfo ui,
MfMailSTMailInfo mi,
boolean bMedium)
Handle Status Change mail with Name/Value pair.
|
protected static MfMailSTMailInfo |
isStatusMail(MboRemote inboundComm,
MfMailGlobalInfo gi,
boolean checkOnly)
Determine whether inboundComm contains mail for Status Change scenario
|
protected void |
processInboundMailST(MboRemote inboundComm,
MfMailSTMailInfo mi,
MfMailGlobalInfo gi,
MXLogger logger) |
protected MfMailSTMailInfo |
readFirstLine(java.lang.String messageBody,
MfMailSTMailInfo mi,
MboRemote trackEntry)
The body may begin with following format
s
shhmm
s memo
shhmm memo
where
s = status value,
hhmm = time of status change,
memo = memo to be added for status change
memo must be separated by single byte space
|
void |
sendSTReplyMail(MboRemote inboundComm,
MboRemote commTemplate,
MboRemote targetMbo,
java.lang.String nextStatus,
MboRemote trackEntry,
UserInfo ui,
java.lang.String secString,
MfMailSTCtrlInfo ctrlInfo,
int deviceClass) |
protected void |
updateTrackEntry(MfMailSTCtrlInfo ci,
MboRemote trackEntry,
MboRemote targetMbo) |
public void applyCustomAction(MboRemote inboundComm, java.lang.Object[] arg1) throws MXException, java.rmi.RemoteException
applyCustomAction in interface ActionCustomClassinboundComm - The Mbo on which the action will apply.MXExceptionjava.rmi.RemoteExceptionActionCustomClass.applyCustomAction(psdi.mbo.MboRemote, java.lang.Object[])protected void processInboundMailST(MboRemote inboundComm, MfMailSTMailInfo mi, MfMailGlobalInfo gi, MXLogger logger) throws java.rmi.RemoteException, MXException
inboundComm - mi - : MfMailHandler class already checked the mail before calling this method.gi - logger - java.rmi.RemoteExceptionMXExceptionprotected static MfMailSTMailInfo isStatusMail(MboRemote inboundComm, MfMailGlobalInfo gi, boolean checkOnly) throws java.rmi.RemoteException, MXException
inboundComm - gi - checkOnly - java.rmi.RemoteExceptionMXExceptionprotected void handleMAXIMOMAILMessageWithNVPair(MboRemote inboundComm, UserInfo ui, MfMailSTMailInfo mi, boolean bMedium) throws java.rmi.RemoteException, MXException
inboundComm - ui - mi - : Class to hold mail informationbMedium - : true for medium, false for smalljava.rmi.RemoteExceptionMXExceptionprotected void handleMAXIMOMAILMessageForVerySmall(MboRemote inboundComm, UserInfo ui, MfMailSTMailInfo miOrig) throws java.rmi.RemoteException, MXException
java.rmi.RemoteExceptionMXExceptionpublic void sendSTReplyMail(MboRemote inboundComm, MboRemote commTemplate, MboRemote targetMbo, java.lang.String nextStatus, MboRemote trackEntry, UserInfo ui, java.lang.String secString, MfMailSTCtrlInfo ctrlInfo, int deviceClass) throws java.rmi.RemoteException, MXException
java.rmi.RemoteExceptionMXExceptionprotected void updateTrackEntry(MfMailSTCtrlInfo ci, MboRemote trackEntry, MboRemote targetMbo) throws java.rmi.RemoteException, MXException
java.rmi.RemoteExceptionMXExceptionprotected java.lang.String getQueryString(java.lang.String subject,
MfMailSTMailInfo mi)
throws java.rmi.RemoteException,
MXException
subject - mi - java.rmi.RemoteExceptionMXExceptionprotected MfMailSTMailInfo readFirstLine(java.lang.String messageBody, MfMailSTMailInfo mi, MboRemote trackEntry) throws MXException, java.rmi.RemoteException
messageBody - mi - java.rmi.RemoteExceptionMXExceptionprotected MboRemote getReplyTemplate(java.lang.String replyTemplateName, UserInfo ui, MboRemote trackEntry, MboRemote target, boolean checkHtml, boolean bRequired) throws java.rmi.RemoteException, MXException
replyTemplateName - ui - trackEntry - target - checkHtml - java.rmi.RemoteExceptionMXExceptionprotected MfMailSTCtrlInfo getNextStatus(MfMailSTMailInfo mi, MboRemote trackEntry, UserInfo ui, MfMailSTCtrlInfo ci) throws java.rmi.RemoteException, MXException
mi - trackEntry - ui - ci - java.rmi.RemoteExceptionMXExceptionprotected MboRemote getTrackEntry(MboRemote targetMbo, java.lang.String MboName, java.lang.String secStr) throws java.rmi.RemoteException, MXException
java.rmi.RemoteExceptionMXExceptionprotected MfMailSTCtrlInfo getControlEntry(java.lang.String MboName, java.lang.String status, UserInfo ui) throws java.rmi.RemoteException, MXException
java.rmi.RemoteExceptionMXExceptionprotected java.lang.String checkAttributes(java.util.Hashtable values,
java.util.HashSet keySet,
boolean bMedium,
MfMailSTCtrlInfo ctrlInfo)
values - hash of values from mailkeySet - hash of key attributesvalidAttList - list of valid attributesprotected java.util.Date adjustToServerTimeZone(java.util.Date srcDate,
UserInfo ui)
srcDate - ui - protected java.util.Date getChangeTime(java.util.Date sendDate,
java.lang.String timeStr,
MboRemote trackEntry,
UserInfo ui)
throws MfMailMXApplicationMailException
sendDate - : Mail send datetimeStr - : Time string in HHMM formattrackEntry - ui - : UserInfo for user time zoneMfMailMXApplicationMailException