public Node previousSibling() {
        if (parentNode == null)
            return null; // root

        if (siblingIndex > 0)
            return parentNode.ensureChildNodes().get(siblingIndex-1);
        else
            return null;
    }
public Node previousSibling ( ) { if ( parentNode == null ) return null ; if ( siblingIndex > 0 ) return parentNode . ensureChildNodes ( ) . get ( siblingIndex - 1 ) ; else return null ; }
Get this node's previous sibling.
@return the previous sibling, or null if this is the first sibling