Add @Override methods accordingly
Fix Document.appendChild() incorrect behavior