Examples of ProcessDocument


Examples of org.oasisOpen.docs.wsbpel.x20.process.executable.ProcessDocument

        .getModelProcessor();

    // Generate BPEL Model
    BpelParserModel m = new BpelParserModel();
    m.createModel(pnp.getElementContainer());
    ProcessDocument doc = ProcessDocument.Factory.newInstance();
    TProcess process = doc.addNewProcess();
//    BPEL.genBpelProcess();
//    BPEL.Process.set(m.generate_bpel());
//    setGlobals(BPEL.Process, pnp);
    process.set(m.generate_bpel());
    setGlobals(process,pnp);
    // File Output
    XmlOptions opt = new XmlOptions();

    //opt.setSavePrettyPrintIndent(2);
    //opt.setUseDefaultNamespace();
    Map<String, String> map = new HashMap<String, String>();
    map.put("http://docs.oasis-open.org/wsbpel/2.0/process/executable",
        "bpel");
    map.put("http://www.w3.org/2001/XMLSchema", "xs");
    opt = opt.setSaveSuggestedPrefixes(map);
    opt.setSavePrettyPrint();
    try
    {
      doc.save(new File(Path), opt);
      //bpelDoc.save(new File(Path), opt);
      return true;
    } catch (IOException e)
    {
      return false;
View Full Code Here

Examples of org.oasisOpen.docs.wsbpel.x20.process.executable.ProcessDocument

    BpelParserModel m = new BpelParserModel();
    if(!m.createModel(pnp.getElementContainer()))
    {
      return "" + Messages.getString("BPEL.genPreview.Error");
    }
    ProcessDocument doc = ProcessDocument.Factory.newInstance();
    TProcess process = doc.addNewProcess();
    setGlobals(process,pnp);
    TProcess tempProc = m.generate_bpel();
    if (tempProc != null)
    {
      setGlobals(tempProc, pnp);
      process.set(tempProc);
    } else
    {
      return "" + Messages.getString("BPEL.genPreview.Error");
    }
    XmlOptions opt = new XmlOptions();
    // opt.setSavePrettyPrintIndent(2);
    // opt.setUseDefaultNamespace();
    Map<String, String> map = new HashMap<String, String>();
    map.put("http://docs.oasis-open.org/wsbpel/2.0/process/executable",
        "bpel");
    map.put("http://www.w3.org/2001/XMLSchema", "xs");
    opt = opt.setSaveSuggestedPrefixes(map);
    opt.setSavePrettyPrint();
    return doc.xmlText(opt);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.