Java XML Node Replace replaceNode(Node oldNode, Node newNode, Node source)

Here you can find the source of replaceNode(Node oldNode, Node newNode, Node source)

Description

replace Node

License

Open Source License

Declaration

public static void replaceNode(Node oldNode, Node newNode, Node source) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

import org.w3c.dom.Node;

public class Main {
    public static void replaceNode(Node oldNode, Node newNode, Node source) {
        source.replaceChild(newNode, oldNode);
    }//from  w w w .  ja  v  a 2 s  .  c o  m
}

Related

  1. replaceComma(Node node)
  2. replaceNode(Node masterNode, Node oldNode, Node newNode)
  3. replaceText(Node node, String text)
  4. replaceVariable(final Node node, final String sVar, final String sValue)
  5. replaceVariable(final Node node, final String var, final String valueString)
  6. replaceWith(Node currentNode, Node replacerNode)