def isResultNode(node):
 return (node and (node.getType() == 'result'))

def isResultNode ( node ) : return ( node and ( node . getType ( ) == 'result' ) )
returns true if the node is a positive reply .