Package org.jdom

Examples of org.jdom.Element.removeContent()


    } else {
//      parameter l�schen
      if(tableIncludeParameter.getSelectionCount()>0) {       
        Element param = (Element)tableIncludeParameter.getSelection()[0].getData("param");
        Element params = ((Element)listOfElement.get(0)).getParentElement();
        params.removeContent(param);
        listOfElement = params.getChildren("param");
        tableIncludeParameter.remove(tableIncludeParameter.getSelectionIndex());
        includeParameterTabItem.setData("params", listOfElement);
      }
    }
View Full Code Here


        _dom.setChanged(true);
        if(_dom.isDirectory() || _dom.isLifeElement()) _dom.setChangedForDirectory("job", Utils.getAttributeValue("name",_job), SchedulerDom.MODIFY);
        return;
      }

      desc.removeContent();
      if (!(f == null || f.equals(""))) {
        setInclude(f);
      }
      desc.addContent(new CDATA(description));
      _dom.setChanged(true);
View Full Code Here

            return;
        }
        Element tagElem = elem.getChild(tagName, elem.getNamespace());
        if (tagElem != null) {
            String updated = CoordELFunctions.evalAndWrap(eval, tagElem.getText());
            tagElem.removeContent();
            tagElem.addContent(updated);
        }
        else {
            LOG.warn(" Value NOT FOUND " + tagName);
        }
View Full Code Here

                xtype = "Queue";
            Attribute xmBeanDD = new Attribute("xmbean-dd", "xmdesc/" + xtype + "-xmbean.xml");
            componentElement.setAttribute(xmBeanDD);
            addNameAttributeToMBeanElement(componentElement, getNameProperty());
        } else {
            componentElement.removeContent();

            // update if the Name has changed
            updateIfNameChanged(componentElement);
        }
View Full Code Here

            componentElement = new Element("mbean");
            Attribute codeAttribute = new Attribute("code", code);
            componentElement.setAttribute(codeAttribute);
            addNameAttributeToMBeanElement(componentElement, getNameProperty());
        } else {
            componentElement.removeContent();

            // update if the Name has changed
            updateIfNameChanged(componentElement);
        }
View Full Code Here

        }
        if (processes.size() == 0) {
            return resultList;
        }
        Element parent = root.getChild("WorkflowProcesses", namespace);
        parent.removeContent();
        Iterator it2 = processes.iterator();
        while (it2.hasNext()) {
            Element rootClone = (Element)root.clone();
            Element newProcess = (Element)it2.next();
            // new Document
View Full Code Here

            Element prop = new Element("prop",davns);
           
            for( Iterator j = c.iterator(); j.hasNext(); )
            {
                Element el = (Element)j.next();
                el.removeContent();
                prop.addContent( el );
            }
           
            propstat.addContent( prop );
            propstat.addContent( new Element("status",davns).setText("HTTP/1.1 200 OK"));
View Full Code Here

            Element prop = new Element("prop",davns);
           
            for( Iterator j = c.iterator(); j.hasNext(); )
            {
                Element el = (Element)j.next();
                el.removeContent();
                prop.addContent( el );
            }
           
            propstat.addContent( prop );
            propstat.addContent( new Element("status",davns).setText("HTTP/1.1 200 OK"));
View Full Code Here

    /** Detach each xml element */
    @Override
    public void processElement(Wrapper<Element> elementWrapper) {
        Element content = elementWrapper.getContent();
        content.detach();
        content.removeContent();
    }

}
View Full Code Here

 
 
  private byte[] buildFinalXML(Document original, Set<ExtendElement> elements) throws IOException {
    ByteArrayOutputStream bos = new ByteArrayOutputStream();
    Element root = (Element)original.getRootElement().clone();
    root.removeContent();
    Document doc = new Document((Element)root.detach(),
        original.getDocType(), original.getBaseURI());
    for(ExtendElement element : elements) {
      root.addContent(element.node.detach());
    }
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.