You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by do...@apache.org on 2011/06/30 00:11:32 UTC
svn commit: r1141278 - in /ofbiz/trunk/framework:
entityext/src/org/ofbiz/entityext/eca/EntityEcaRule.java
service/src/org/ofbiz/service/eca/ServiceEcaRule.java
Author: doogie
Date: Wed Jun 29 22:11:32 2011
New Revision: 1141278
URL: http://svn.apache.org/viewvc?rev=1141278&view=rev
Log:
OPTIMIZE: Make these classes final.
Modified:
ofbiz/trunk/framework/entityext/src/org/ofbiz/entityext/eca/EntityEcaRule.java
ofbiz/trunk/framework/service/src/org/ofbiz/service/eca/ServiceEcaRule.java
Modified: ofbiz/trunk/framework/entityext/src/org/ofbiz/entityext/eca/EntityEcaRule.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/entityext/src/org/ofbiz/entityext/eca/EntityEcaRule.java?rev=1141278&r1=1141277&r2=1141278&view=diff
==============================================================================
--- ofbiz/trunk/framework/entityext/src/org/ofbiz/entityext/eca/EntityEcaRule.java (original)
+++ ofbiz/trunk/framework/entityext/src/org/ofbiz/entityext/eca/EntityEcaRule.java Wed Jun 29 22:11:32 2011
@@ -37,7 +37,7 @@ import org.w3c.dom.Element;
* EntityEcaRule
*/
@SuppressWarnings("serial")
-public class EntityEcaRule implements java.io.Serializable {
+public final class EntityEcaRule implements java.io.Serializable {
public static final String module = EntityEcaRule.class.getName();
@@ -47,16 +47,14 @@ public class EntityEcaRule implements ja
nameSet.add("action");
}
- protected String entityName = null;
- protected String operationName = null;
- protected String eventName = null;
- protected boolean runOnError = false;
- protected List<EntityEcaCondition> conditions = FastList.newInstance();
- protected List<Object> actionsAndSets = FastList.newInstance();
+ protected final String entityName;
+ protected final String operationName;
+ protected final String eventName;
+ protected final boolean runOnError;
+ protected final List<EntityEcaCondition> conditions = FastList.newInstance();
+ protected final List<Object> actionsAndSets = FastList.newInstance();
protected boolean enabled = true;
- protected EntityEcaRule() {}
-
public EntityEcaRule(Element eca) {
this.entityName = eca.getAttribute("entity");
this.operationName = eca.getAttribute("operation");
Modified: ofbiz/trunk/framework/service/src/org/ofbiz/service/eca/ServiceEcaRule.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/service/src/org/ofbiz/service/eca/ServiceEcaRule.java?rev=1141278&r1=1141277&r2=1141278&view=diff
==============================================================================
--- ofbiz/trunk/framework/service/src/org/ofbiz/service/eca/ServiceEcaRule.java (original)
+++ ofbiz/trunk/framework/service/src/org/ofbiz/service/eca/ServiceEcaRule.java Wed Jun 29 22:11:32 2011
@@ -36,20 +36,18 @@ import org.w3c.dom.Element;
* ServiceEcaRule
*/
@SuppressWarnings("serial")
-public class ServiceEcaRule implements java.io.Serializable {
+public final class ServiceEcaRule implements java.io.Serializable {
public static final String module = ServiceEcaRule.class.getName();
- protected String serviceName = null;
- protected String eventName = null;
- protected boolean runOnFailure = false;
- protected boolean runOnError = false;
- protected List<ServiceEcaCondition> conditions = FastList.newInstance();
- protected List<Object> actionsAndSets = FastList.newInstance();
+ protected final String serviceName;
+ protected final String eventName;
+ protected final boolean runOnFailure;
+ protected final boolean runOnError;
+ protected final List<ServiceEcaCondition> conditions = FastList.newInstance();
+ protected final List<Object> actionsAndSets = FastList.newInstance();
protected boolean enabled = true;
- protected String definitionLocation = null;
-
- protected ServiceEcaRule() {}
+ protected final String definitionLocation;
public ServiceEcaRule(Element eca, String definitionLocation) {
this.definitionLocation = definitionLocation;