com.ibm.tivoli.maximo.mfmail

Class MfMailSTUpdateHandler

  • java.lang.Object
    • com.ibm.tivoli.maximo.mfmail.MfMailSTUpdateHandler
    • Constructor Detail

      • MfMailSTUpdateHandler

        public MfMailSTUpdateHandler()
    • Method Detail

      • processInboundMailST

        protected void processInboundMailST(MboRemote inboundComm,
                                            MfMailSTMailInfo mi,
                                            MfMailGlobalInfo gi,
                                            MXLogger logger)
                                     throws java.rmi.RemoteException,
                                            MXException
        Parameters:
        inboundComm -
        mi - : MfMailHandler class already checked the mail before calling this method.
        gi -
        logger -
        Throws:
        java.rmi.RemoteException
        MXException
      • isStatusMail

        protected static MfMailSTMailInfo isStatusMail(MboRemote inboundComm,
                                                       MfMailGlobalInfo gi,
                                                       boolean checkOnly)
                                                throws java.rmi.RemoteException,
                                                       MXException
        Determine whether inboundComm contains mail for Status Change scenario
        Parameters:
        inboundComm -
        gi -
        checkOnly -
        Returns:
        Throws:
        java.rmi.RemoteException
        MXException
      • handleMAXIMOMAILMessageWithNVPair

        protected void handleMAXIMOMAILMessageWithNVPair(MboRemote inboundComm,
                                                         UserInfo ui,
                                                         MfMailSTMailInfo mi,
                                                         boolean bMedium)
                                                  throws java.rmi.RemoteException,
                                                         MXException
        Handle Status Change mail with Name/Value pair. For medium device, name/value pair contains everything. For small device, name/value pair contains information to identify target Mbo, and first line of body shall have status selection number.
        Parameters:
        inboundComm -
        ui -
        mi - : Class to hold mail information
        bMedium - : true for medium, false for small
        Throws:
        java.rmi.RemoteException
        MXException
      • getQueryString

        protected java.lang.String getQueryString(java.lang.String subject,
                                                  MfMailSTMailInfo mi)
                                           throws java.rmi.RemoteException,
                                                  MXException
        Create query string to retrieve targetMbo from subject line for small device
        Parameters:
        subject -
        mi -
        Returns:
        Throws:
        java.rmi.RemoteException
        MXException
      • readFirstLine

        protected MfMailSTMailInfo readFirstLine(java.lang.String messageBody,
                                                 MfMailSTMailInfo mi,
                                                 MboRemote trackEntry)
                                          throws MXException,
                                                 java.rmi.RemoteException
        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
        Parameters:
        messageBody -
        mi -
        Returns:
        Throws:
        java.rmi.RemoteException
        MXException
      • getReplyTemplate

        protected MboRemote getReplyTemplate(java.lang.String replyTemplateName,
                                             UserInfo ui,
                                             MboRemote trackEntry,
                                             MboRemote target,
                                             boolean checkHtml,
                                             boolean bRequired)
                                      throws java.rmi.RemoteException,
                                             MXException
        Get communication template for reply. (Previously this method is used to retrieve communication template with special suffix when it is for html mail. With Maximo 7.1.1.7 mxe.email.content.type property support, this functionality has removed.)
        Parameters:
        replyTemplateName -
        ui -
        trackEntry -
        target -
        checkHtml -
        Returns:
        Throws:
        java.rmi.RemoteException
        MXException
      • getTrackEntry

        protected MboRemote getTrackEntry(MboRemote targetMbo,
                                          java.lang.String MboName,
                                          java.lang.String secStr)
                                   throws java.rmi.RemoteException,
                                          MXException
        Throws:
        java.rmi.RemoteException
        MXException
      • checkAttributes

        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.
        Parameters:
        values - hash of values from mail
        keySet - hash of key attributes
        validAttList - list of valid attributes
        Returns:
        When all attributes are included in validAttList, then returns null Otherwise, returns first attribute not in the list.
      • adjustToServerTimeZone

        protected java.util.Date adjustToServerTimeZone(java.util.Date srcDate,
                                                        UserInfo ui)
        Method to convert time between user timezone and server timezone
        Parameters:
        srcDate -
        ui -
        Returns:
      • getChangeTime

        protected java.util.Date getChangeTime(java.util.Date sendDate,
                                               java.lang.String timeStr,
                                               MboRemote trackEntry,
                                               UserInfo ui)
                                        throws MfMailMXApplicationMailException
        Method to calculate change time from time in HHMM format
        Parameters:
        sendDate - : Mail send date
        timeStr - : Time string in HHMM format
        trackEntry -
        ui - : UserInfo for user time zone
        Returns:
        : Change Date or sendDate
        Throws:
        MfMailMXApplicationMailException