|
From: <caw...@us...> - 2007-03-18 13:42:35
|
Revision: 2198
http://svn.sourceforge.net/rubyeclipse/?rev=2198&view=rev
Author: cawilliams
Date: 2007-03-17 08:02:31 -0700 (Sat, 17 Mar 2007)
Log Message:
-----------
add more hooks to perform analysis
Modified Paths:
--------------
trunk/org.rubypeople.rdt.core/src/org/rubypeople/rdt/internal/core/parser/warnings/RubyLintVisitor.java
Modified: trunk/org.rubypeople.rdt.core/src/org/rubypeople/rdt/internal/core/parser/warnings/RubyLintVisitor.java
===================================================================
--- trunk/org.rubypeople.rdt.core/src/org/rubypeople/rdt/internal/core/parser/warnings/RubyLintVisitor.java 2007-03-16 19:44:25 UTC (rev 2197)
+++ trunk/org.rubypeople.rdt.core/src/org/rubypeople/rdt/internal/core/parser/warnings/RubyLintVisitor.java 2007-03-17 15:02:31 UTC (rev 2198)
@@ -1,6 +1,14 @@
package org.rubypeople.rdt.internal.core.parser.warnings;
+import org.jruby.ast.BlockNode;
+import org.jruby.ast.ClassNode;
+import org.jruby.ast.DefnNode;
+import org.jruby.ast.DefsNode;
+import org.jruby.ast.IfNode;
+import org.jruby.ast.ModuleNode;
import org.jruby.ast.Node;
+import org.jruby.ast.SClassNode;
+import org.jruby.ast.WhenNode;
import org.jruby.ast.visitor.AbstractVisitor;
import org.jruby.evaluator.Instruction;
import org.jruby.lexer.yacc.ISourcePosition;
@@ -47,7 +55,55 @@
* @return a String key
*/
abstract protected String getOptionKey();
+
+ /**
+ * Meant to be overriden by classes needing to perform some action when a class definition was exited.
+ * @param iVisited
+ */
+ public void exitClassNode(ClassNode iVisited) {}
+
+ /**
+ * To be overriden by subclasses who need to run particular behavior/code when exiting a method definition.
+ * @param iVisited
+ */
+ public void exitDefnNode(DefnNode iVisited) {}
+
+ /**
+ * To be overriden by subclasses who need to run particular behavior/code when exiting a singleton method definition.
+ * @param iVisited
+ */
+ public void exitIfNode(IfNode iVisited) {}
+
+ /**
+ * To be overriden by subclasses who need to run particular behavior/code when exiting a singleton method definition.
+ * @param iVisited
+ */
+ public void exitBlockNode(BlockNode iVisited) {}
+
+ /**
+ * To be overriden by subclasses who need to run particular behavior/code when exiting a singleton method definition.
+ * @param iVisited
+ */
+ public void exitDefsNode(DefsNode iVisited) {}
+
+ /**
+ * To be overriden by subclasses who need to run particular behavior/code when exiting a singleton method definition.
+ * @param iVisited
+ */
+ public void exitModuleNode(ModuleNode iVisited) {}
+ /**
+ * To be overriden by subclasses who need to run particular behavior/code when exiting a singleton method definition.
+ * @param iVisited
+ */
+ public void exitWhenNode(WhenNode iVisited) {}
+
+ /**
+ * To be overriden by subclasses who need to run particular behavior/code when exiting a singleton method definition.
+ * @param iVisited
+ */
+ public void exitSClassNode(SClassNode iVisited) {}
+
protected int getProblemID() {
return IProblem.Uncategorized;
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|