public Method

Node.find(conditions)

Search the children of this node for the first node for which #find returns non nil. Returns the result of the #find call that succeeded.

Source Code

# File action_controller/vendor/html-scanner/html/node.rb, line 93
def find(conditions)
  conditions = validate_conditions(conditions)
  @children.each do |child|        
    node = child.find(conditions)
    return node if node
  end
  nil
end
Comments

Have your say
Please use Textile formatting (click here for a cheat sheet). Use <code/> and <pre/> for code samples.
Click here to login with OpenID to to post comments.