Package org.jdom

Examples of org.jdom.Element.removeAttribute()


    out.close();
    Element object3 = new Element("object");

    Properties raw = loadObject(object3,home+"users/"+credentials.getProperty("username")+"/dc/"+object.getAttributeValue("resourceguid")+"/");
    object3.removeChildren("attribute");
    object3.removeAttribute("resourceid");
    object3.removeAttribute("entitytype");
    transaction.addContent(object3);

    Properties info = (Properties)raw.get("info");
    Properties attributes = (Properties)raw.get("attributes");
View Full Code Here


    Element object3 = new Element("object");

    Properties raw = loadObject(object3,home+"users/"+credentials.getProperty("username")+"/dc/"+object.getAttributeValue("resourceguid")+"/");
    object3.removeChildren("attribute");
    object3.removeAttribute("resourceid");
    object3.removeAttribute("entitytype");
    transaction.addContent(object3);

    Properties info = (Properties)raw.get("info");
    Properties attributes = (Properties)raw.get("attributes");
    attributes.put("storageconsumed",fileData.length()+"");
View Full Code Here

    in.close();
    fileData = new String(b);
    Element object3 = new Element("object");

    object3.removeChildren("attribute");
    object3.removeAttribute("resourceid");
    object3.removeAttribute("entitytype");
    transaction.addContent(object3);
    Element file2 = new Element("file");
    object3.addContent(file2);
    file2.setAttribute("length",fileData.length()+"");
View Full Code Here

    fileData = new String(b);
    Element object3 = new Element("object");

    object3.removeChildren("attribute");
    object3.removeAttribute("resourceid");
    object3.removeAttribute("entitytype");
    transaction.addContent(object3);
    Element file2 = new Element("file");
    object3.addContent(file2);
    file2.setAttribute("length",fileData.length()+"");
    file2.setText("___fileData___");
View Full Code Here

                                                       "more_more_text03",
                                                       "elem033"};

        Element elem03 = rootElement.getChild("elem03");
        elem03.getContent().remove(3)//elem032
        elem03.removeAttribute("attr03");

        undoRedoManager.demarcateUOW();

        elem03.getContent().remove(0); //text03
        elem03.removeChild("elem031");
View Full Code Here

            if (childElement.getName().equalsIgnoreCase("vsselement")) {
                Iterator vssAttributeIterator = childElement.getAttributes().iterator();
                while (vssAttributeIterator.hasNext()) {
                    Attribute attribute = (Attribute) vssAttributeIterator.next();
                    if (attribute.getName().equalsIgnoreCase("ssdir")) {
                        childElement.removeAttribute("ssdir");
                        childElement.setAttribute("vsspath", attribute.getValue());
                    }
                }
            }
            //correct vss naming scheme
View Full Code Here

        }
        if (pluginClassName == null) {
            pluginClassName = getPluginClassname(pluginName);
        }
        Element clonedPluginElement = (Element) pluginElement.clone();
        clonedPluginElement.removeAttribute("name");
        clonedPluginElement.removeAttribute("classname");
        clonedPluginElement.setName(pluginName);
        if (LOG.isDebugEnabled()) {
            LOG.debug("storing plugin configuration " + pluginName);
        }
View Full Code Here

        if (pluginClassName == null) {
            pluginClassName = getPluginClassname(pluginName);
        }
        Element clonedPluginElement = (Element) pluginElement.clone();
        clonedPluginElement.removeAttribute("name");
        clonedPluginElement.removeAttribute("classname");
        clonedPluginElement.setName(pluginName);
        if (LOG.isDebugEnabled()) {
            LOG.debug("storing plugin configuration " + pluginName);
        }
        pluginConfigs.put(pluginName, clonedPluginElement);
View Full Code Here

        for (Map.Entry<String, XmlFile> entry : schemaInfo.entrySet()) {
          XmlFile xf = entry.getValue();
          String fname = entry.getKey();
          Element response = xf.exec(new Element("junk"), context);
          response.setName(FilenameUtils.removeExtension(fname));
                    response.removeAttribute("noNamespaceSchemaLocation", Geonet.Namespaces.XSI);
          Element schemaElem = new Element(schema);
          schemaElem.addContent(response);
          schemas.addContent(schemaElem);
        }
      } catch (Exception e) {
View Full Code Here

    if(cache) {
        cache(context.getUserSession(), elMd, id);
    }
    if (removeSchemaLocation) {
        elMd.removeAttribute("schemaLocation", Xml.xsiNS);
    }
    return elMd;
  }

  private final static String KEY = "SHOW_METADATA";
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.