Changeset 1666

Show
Ignore:
Timestamp:
11/16/07 19:45:22 (6 years ago)
Author:
gyuque
Message:

lang/javascript/javascript-xpath: updated analyzer (show NodeUtil? calls)

Location:
lang/javascript/javascript-xpath/trunk
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • lang/javascript/javascript-xpath/trunk/src/jxanalyzer.js

    r1664 r1666  
    135135 
    136136                        } 
     137                } 
     138                else if (e.name == "attrMatch") 
     139                { 
     140                        e.attrMatchName = e.args[1]; 
     141                        e.attrMatchVal = e.args[2]; 
    137142                } 
    138143                 
     
    418423        }, 
    419424         
     425        makeAttrMatchEventLog: function(e) { 
     426                var P = document.createElement("p"); 
     427                P.innerHTML = this.createBasicLog(e).join('') + "@"+e.attrMatchName + " == " +e.attrMatchVal +"   at start + "+e.ET; 
     428                 
     429                return P; 
     430        }, 
     431 
     432        makeGetDescendantNodesEventLog: function(e) { 
     433                var P = document.createElement("p"); 
     434                P.innerHTML = this.createBasicLog(e).join('') + "   at start + "+e.ET; 
     435                 
     436                return P; 
     437        }, 
     438         
    420439        commit: function() { 
    421440                this.usedContexts.push(this.ctx); 
     
    482501        JXAnalyzer.hookMethod(NodeSet.prototype, "doDel", Azr, true); 
    483502        JXAnalyzer.hookMethod(NodeSet.prototype, "delDescendant", Azr, true); 
     503         
     504        JXAnalyzer.hookMethod(NodeUtil, "attrMatch", Azr); 
     505        JXAnalyzer.hookMethod(NodeUtil, "getDescendantNodes", Azr); 
     506        NodeUtil._parser_name = "NodeUtil"; 
    484507 
    485508        JXAnalyzer.hookMethod(Lexer.prototype, "next", Azr, true); 
  • lang/javascript/javascript-xpath/trunk/test/functional/analyzer.css

    r1651 r1666  
    6565.az-compare-call { 
    6666    background-color: #461; 
     67    color: #fff; 
     68} 
     69 
     70.az-attrMatch-call, 
     71.az-getDescendantNodes-call { 
     72    background-color: #694; 
    6773    color: #fff; 
    6874}