src/PHPHtmlParser/Dom/AbstractNode.php
public function hasNextSibling(): bool
    {
        try
        {
            $this->nextSibling();

            // sibling found, return true;
            return true;
        }
        catch (ParentNotFoundException $e)
        {
            // no parent, no next sibling
            return false;
        }
        catch (ChildNotFoundException $e)
        {
            // no sibling found
            return false;
        }
    }
public function hasNextSibling(): bool
    {
        try
        {
            $this->nextSibling();

            // sibling found, return true;
            return true;
        }
        catch (ParentNotFoundException $e)
        {
            // no parent, no next sibling
            return false;
        }
        catch (ChildNotFoundException $e)
        {
            // no sibling found
            return false;
        }
    }
public function hasNextSibling ( ) : bool { try { $ this -> nextSibling ( ) ; // sibling found, return true; return true ; } catch ( ParentNotFoundException $ e ) { // no parent, no next sibling return false ; } catch ( ChildNotFoundException $ e ) { // no sibling found return false ; } }
Checks if the current node has a next sibling.

@return bool
Checks if the current node has a next sibling .