[jboss-svn-commits] JBL Code SVN: r28227 - labs/jbossrules/trunk/drools-compiler/src/main/java/org/drools/guvnor/server/util.

jboss-svn-commits at lists.jboss.org jboss-svn-commits at lists.jboss.org
Sun Jul 19 21:19:21 EDT 2009


Author: michael.neale at jboss.com
Date: 2009-07-19 21:19:21 -0400 (Sun, 19 Jul 2009)
New Revision: 28227

Modified:
   labs/jbossrules/trunk/drools-compiler/src/main/java/org/drools/guvnor/server/util/GuidedDTDRLPersistence.java
Log:
cleaned up to not use a type erasure confusing overloaded method "find" (was private anyway). Upset some compilers.

Modified: labs/jbossrules/trunk/drools-compiler/src/main/java/org/drools/guvnor/server/util/GuidedDTDRLPersistence.java
===================================================================
--- labs/jbossrules/trunk/drools-compiler/src/main/java/org/drools/guvnor/server/util/GuidedDTDRLPersistence.java	2009-07-20 01:09:00 UTC (rev 28226)
+++ labs/jbossrules/trunk/drools-compiler/src/main/java/org/drools/guvnor/server/util/GuidedDTDRLPersistence.java	2009-07-20 01:19:21 UTC (rev 28227)
@@ -79,7 +79,7 @@
 			if (validCell(cell)) {
 				if (c instanceof ActionInsertFactCol) {
 					ActionInsertFactCol ac = (ActionInsertFactCol)c;
-					LabelledAction a = find(actions, ac.boundName);
+					LabelledAction a = findByLabelledAction(actions, ac.boundName);
 					if (a == null) {
 						a = new LabelledAction();
 						a.boundName  = ac.boundName;
@@ -92,7 +92,7 @@
 					ins.addFieldValue(val);
 				} else if (c instanceof ActionRetractFactCol) {
 					ActionRetractFactCol rf = (ActionRetractFactCol)c;
-					LabelledAction a = find(actions, rf.boundName);
+					LabelledAction a = findByLabelledAction(actions, rf.boundName);
 					if (a == null) {
 						a = new LabelledAction();
 						a.action = new ActionRetractFact(rf.boundName);
@@ -101,7 +101,7 @@
 					}
 				} else if (c instanceof ActionSetFieldCol) {
 					ActionSetFieldCol sf = (ActionSetFieldCol)c;
-					LabelledAction a = find(actions, sf.boundName);
+					LabelledAction a = findByLabelledAction(actions, sf.boundName);
 					if (a == null) {
 						a = new LabelledAction();
 						a.boundName = sf.boundName;
@@ -131,7 +131,7 @@
 		}
 	}
 
-	private LabelledAction find(List<LabelledAction> actions, String boundName) {
+	private LabelledAction findByLabelledAction(List<LabelledAction> actions, String boundName) {
 		for (LabelledAction labelledAction : actions) {
 			if (labelledAction.boundName.equals(boundName)) {
 				return labelledAction;
@@ -156,7 +156,7 @@
 			if (validCell(cell)) {
 
 				//get or create the pattern it belongs too
-				FactPattern fp = find(patterns, c.boundName);
+				FactPattern fp = findByFactPattern(patterns, c.boundName);
 				if (fp == null) {
 					fp = new FactPattern(c.factType);
 					fp.boundName = c.boundName;
@@ -206,7 +206,7 @@
 		return operator == null || "".equals(operator);
 	}
 
-	private FactPattern find(List<FactPattern> patterns, String boundName) {
+	private FactPattern findByFactPattern(List<FactPattern> patterns, String boundName) {
 		for (FactPattern factPattern : patterns) {
 			if (factPattern.boundName.equals(boundName)) {
 				return factPattern;



More information about the jboss-svn-commits mailing list