Package org.enhydra.shark.xpdl

Examples of org.enhydra.shark.xpdl.XMLElement


   protected void fillTableContent(List elementsToShow) {
      DefaultTableModel dtm = (DefaultTableModel) allItems.getModel();
      Iterator it = elementsToShow.iterator();

      while (it.hasNext()) {
         XMLElement elem = (XMLElement) it.next();
         Vector v = getRow(elem);
         dtm.addRow(v);
      }
   }
View Full Code Here


         Iterator itAllElems = columnsToShow.iterator();
         v = new Vector();
         XMLComplexElement cmel=(XMLComplexElement) elem;
         while (itAllElems.hasNext()) {
            String elName=(String)itAllElems.next();
            XMLElement el = cmel.get(elName);
            if (el!=null) {
               v.add(new XMLElementView(ipc,el, XMLElementView.TOVALUE));
            }
         }
      } else {
View Full Code Here

   public void xmlElementChanged(XMLElementChangeInfo info) {
      if (info.getAction() == XMLElementChangeInfo.REMOVED) {
         Iterator it = info.getChangedSubElements().iterator();
         while (it.hasNext()) {
            XMLElement el = (XMLElement) it.next();
            int row = getElementRow(el);
//            System.out.println("Removing row " + row + " for element " + el);
            if (row != -1) {
               removeRow(row);
            }
         }
      } else if (info.getAction() == XMLElementChangeInfo.INSERTED) {
         Iterator it = info.getChangedSubElements().iterator();
         while (it.hasNext()) {
            XMLElement el = (XMLElement) it.next();
            addRow(el);
         }
      }
   }
View Full Code Here

   }

   protected int getElementRow(XMLElement el) {
      int row = -1;
      for (int i = 0; i < allItems.getRowCount(); i++) {
         XMLElement toCompare = (XMLElement) allItems.getValueAt(i, 0);
         if (el==toCompare) {
            row = i;
            break;
         }
      }
View Full Code Here

   }

   protected void adjustActions() {
      JaWEController jc = JaWEManager.getInstance().getJaWEController();

      XMLElement selEl=getSelectedElement();
      newElementAction.setEnabled(jc.canCreateElement((XMLCollection) getOwner()));
      editElementAction.setEnabled((selEl != null && XMLUtil.getPackage(selEl)!=null));
      deleteElementAction.setEnabled((selEl != null && jc.canRemoveElement((XMLCollection)getOwner(), selEl)));

      boolean canRepos = JaWEManager.getInstance().getJaWEController().canRepositionElement((XMLCollection) getOwner(),
View Full Code Here

TOP

Related Classes of org.enhydra.shark.xpdl.XMLElement

Copyright © 2018 www.massapicom. 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.