Beispielhafte Abbildung eines Geschäftsprozesses in MEMO OrgML auf einen Workflow in XPDL.


    MetaEdit+ (MetaCase):
  1. Dekompositionsdiagramm

  2. Prozessmodell

  3. Workflow- und Aktivitätsspezifikationsdiagramm

  4. Generierung der Workflow Spezifikation in XPDL


  5. Shark (Enhydra):

  6. E-Mail-Anwendung in Java

  7. Abbilden von XPDL 'Participants' auf Users in Shark

  8. Abbilden von XPDL 'Applications' auf Prozeduren in Shark

  9. Workflow instanziieren





Contents of ./info/workflow/java/WfSimpleMailSender.java

Download plain text file of java/WfSimpleMailSender.java
/*
 * Created on 05.04.2004
 *
 * WfM Application for ECOMOD
 *
 */
package wfmapps;

import java.io.IOException;

import org.omg.CORBA.Any;
import org.omg.CORBA.BAD_OPERATION;

/**
 * @author jjung
 *
 * WfM Application for ECOMOD
 *
 */
public class WfSimpleMailSender {
    
    public static void execute(Any aReceiver, Any aText, Any isSent){
        
        try {
            /*Default parameters:
             * host: mailserver for sending mails
             * from: email-address of the sender
             * name: name of the sender
             * subj: subject*/
            String host = "mailhost.uni-koblenz.de";
            String from = "ecomod@uni-koblenz.de";
            String name = "ECOMOD WfMS";
            String subj = "Message from ECOMOD WfMS";

            /*Passed parameters:
             * receiver: email-address of the receiver
             * text: message body*/
            String receiver = aReceiver.extract_string();
            String text = aText.extract_string();

            //Construct command-line for external mail-tool
            StringBuffer command = new StringBuffer("c:\\xpdl\\apps\\mail\\netmailbot");
            command.append(" -to "); command.append(receiver);
            command.append(" -from "); command.append(from);
            command.append(" -fromfriendly "); command.append("\""+name+"\"");
            command.append(" -subject "); command.append("\""+subj+"\"");
            command.append(" -server "); command.append(host);
            command.append(" -body "); command.append("\""+text+"\"");
            
            //Call external mail-tool
            Runtime rt = Runtime.getRuntime();
            rt.exec(command.toString()); 
            /*The mail is assumed to be sent
             * if no error occured*/
            isSent.insert_boolean(true);
        } catch (BAD_OPERATION e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        } catch (IOException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        }
    }
}