You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by sa...@apache.org on 2012/06/17 11:21:30 UTC
svn commit: r1351078 [2/4] - in /ofbiz/branches/jackrabbit20120501: ./
applications/accounting/script/org/ofbiz/accounting/rate/
applications/accounting/webapp/accounting/WEB-INF/
applications/manufacturing/src/org/ofbiz/manufacturing/jobshopmgt/ appli...
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/dtd/simple-methods-v2.xsd
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/dtd/simple-methods-v2.xsd?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/dtd/simple-methods-v2.xsd (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/dtd/simple-methods-v2.xsd Sun Jun 17 09:21:27 2012
@@ -4207,58 +4207,71 @@ under the License.
<xs:element name="property-to-field" substitutionGroup="OtherOperations">
<xs:annotation>
<xs:documentation>
- The property-to-field tag puts the inlined string value in the specified field.
+ Assigns a property value to a field.
</xs:documentation>
</xs:annotation>
<xs:complexType>
- <xs:attributeGroup ref="attlist.property-to-field"/>
+ <xs:attribute ref="field" />
+ <xs:attribute type="xs:string" name="resource" use="required">
+ <xs:annotation>
+ <xs:documentation>
+ The name of a properties resource. Can be a file on the classpath or
+ a resource defined in the SystemProperty entity.
+ <br/><br/>
+ Required. Attribute types: constant, ${expression}.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute type="xs:string" name="property" use="required">
+ <xs:annotation>
+ <xs:documentation>
+ The property whose value will be put in the field.
+ <br/><br/>
+ Required. Attribute types: constant, ${expression}.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute type="xs:string" name="default">
+ <xs:annotation>
+ <xs:documentation>
+ The default value to use if the specified property value is null or empty.
+ <br/><br/>
+ Optional. Attribute types: constant, ${expression}.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute type="booleanConst" name="no-locale">
+ <xs:annotation>
+ <xs:documentation>
+ Suppress property value localization. The user's/system locale will be ignored
+ when retriving the property value.
+ Defaults to "false".
+ <br/><br/>
+ Optional. Attribute type: constant.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute type="xs:string" name="arg-list">
+ <xs:annotation>
+ <xs:documentation>
+ An argument list to be used with a formatting string.
+ The argument list is applied to the property value.
+ Does nothing if the argument list is not found.
+ See the java.text.MessageFormat class for more information.
+ <br/><br/>
+ Optional. Attribute type: expression.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute type="xs:string" name="arg-list-name">
+ <xs:annotation>
+ <xs:documentation>
+ Deprecated - use the arg-list attribute.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
</xs:complexType>
</xs:element>
- <xs:attributeGroup name="attlist.property-to-field">
- <xs:attribute type="xs:string" name="resource" use="required">
- <xs:annotation>
- <xs:documentation>
- Name of a properties file on the classpath.
- </xs:documentation>
- </xs:annotation>
- </xs:attribute>
- <xs:attribute type="xs:string" name="property" use="required">
- <xs:annotation>
- <xs:documentation>
- The property whose value will be put in the field.
- </xs:documentation>
- </xs:annotation>
- </xs:attribute>
- <xs:attribute type="xs:string" name="field" use="required">
- <xs:annotation>
- <xs:documentation>
- The name (key) of the map field to use.
- </xs:documentation>
- </xs:annotation>
- </xs:attribute>
- <xs:attribute type="xs:string" name="default">
- <xs:annotation>
- <xs:documentation>
- The default value to use if the specified property is empty.
- </xs:documentation>
- </xs:annotation>
- </xs:attribute>
- <xs:attribute name="no-locale" default="false">
- <xs:annotation>
- <xs:documentation>
- If sets to true don't use the default locale variable.
- Defaults to false.
- </xs:documentation>
- </xs:annotation>
- <xs:simpleType>
- <xs:restriction base="xs:token">
- <xs:enumeration value="true"/>
- <xs:enumeration value="false"/>
- </xs:restriction>
- </xs:simpleType>
- </xs:attribute>
- <xs:attribute type="xs:string" name="arg-list-name"/>
- </xs:attributeGroup>
<xs:element name="set-current-user-login" substitutionGroup="OtherOperations">
<xs:annotation>
<xs:documentation>
@@ -4284,141 +4297,197 @@ under the License.
<xs:element name="calculate" substitutionGroup="OtherOperations">
<xs:annotation>
<xs:documentation>
- The calculate tag performs the specified calculation and puts the result in an object in the field of the specified map (see the calculate element attribute descriptions).
- The type of the object can be specified with the type attribute, defaults to Double.
-
- The calculate tag can contain calcop and number tags, and the calcop tag can also contain these two tags to enable nested calculations.
-
- The operator specifies the operation to perform on the given field and nested calcops and numbers.
- It must be one of the following: get | add | subtract | multiply | divide | negative.
+ Performs an arithmetic calculation and puts the result in the specified field.
+ Deprecated - use the set element.
</xs:documentation>
</xs:annotation>
<xs:complexType>
<xs:choice minOccurs="0" maxOccurs="unbounded">
- <xs:element ref="calcop">
- <xs:annotation>
- <xs:documentation>
- This tag is used to apply an operator in the calculation.
- It can have calcop and number tags nested under it, making it also act like a parenthesis.
- It has three attributes: operator, map-name, and field-name. Operator and field-name are required.
- </xs:documentation>
- </xs:annotation>
- </xs:element>
- <xs:element ref="number"/>
+ <xs:element ref="calcop" />
+ <xs:element ref="number" />
</xs:choice>
- <xs:attributeGroup ref="attlist.calculate"/>
+ <xs:attribute ref="field" />
+ <xs:attribute name="rounding-mode">
+ <xs:annotation>
+ <xs:documentation>
+ Rounding mode for BigDecimal calculation, primarily for divide operation.
+ Defaults to "HalfEven".
+ <br/><br/>
+ Optional. Attribute types: constant, ${expression}.
+ </xs:documentation>
+ </xs:annotation>
+ <xs:simpleType>
+ <xs:restriction base="xs:token">
+ <xs:enumeration value="Ceiling">
+ <xs:annotation>
+ <xs:documentation>
+ Round towards positive infinity.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:enumeration>
+ <xs:enumeration value="Floor">
+ <xs:annotation>
+ <xs:documentation>
+ Round towards negative infinity.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:enumeration>
+ <xs:enumeration value="Up">
+ <xs:annotation>
+ <xs:documentation>
+ Round towards "nearest neighbor" unless both neighbors are equidistant, in which case round up.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:enumeration>
+ <xs:enumeration value="Down">
+ <xs:annotation>
+ <xs:documentation>
+ Round towards "nearest neighbor" unless both neighbors are equidistant, in which case round down.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:enumeration>
+ <xs:enumeration value="HalfUp">
+ <xs:annotation>
+ <xs:documentation>
+ Round towards "nearest neighbor" unless both neighbors are equidistant, in which case round up.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:enumeration>
+ <xs:enumeration value="HalfDown">
+ <xs:annotation>
+ <xs:documentation>
+ Round towards "nearest neighbor" unless both neighbors are equidistant, in which case round down.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:enumeration>
+ <xs:enumeration value="HalfEven">
+ <xs:annotation>
+ <xs:documentation>
+ Round towards the "nearest neighbor" unless both neighbors are equidistant, in which case, round towards the even neighbor.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:enumeration>
+ <xs:enumeration value="Unnecessary">
+ <xs:annotation>
+ <xs:documentation>
+ Asserts that the requested operation has an exact result, hence no rounding is necessary.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:enumeration>
+ <xs:enumeration value="${roundingMode}">
+ <xs:annotation>
+ <xs:documentation>
+ Convention for variable name for this attribute, in cases where it is determined at run-time.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:enumeration>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
+ <xs:attribute type="xs:string" name="decimal-scale">
+ <xs:annotation>
+ <xs:documentation>
+ Initial scale to use for the internal BigDecimal. Defaults to "2".
+ <br/><br/>
+ Optional. Attribute types: constant, ${expression}.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute type="xs:string" name="decimal-format">
+ <xs:annotation>
+ <xs:documentation>
+ Decimal format to use for conversion to string.
+ <br/><br/>
+ Optional. Attribute types: constant, ${expression}.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="type">
+ <xs:annotation>
+ <xs:documentation>
+ Data type of the calculation result. Defaults to "BigDecimal".
+ <br/><br/>
+ Optional. Attribute types: constant, ${expression}.
+ </xs:documentation>
+ </xs:annotation>
+ <xs:simpleType>
+ <xs:restriction base="xs:token">
+ <xs:enumeration value="String" />
+ <xs:enumeration value="Double" />
+ <xs:enumeration value="Float" />
+ <xs:enumeration value="Long" />
+ <xs:enumeration value="Integer" />
+ <xs:enumeration value="BigDecimal" />
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
</xs:complexType>
</xs:element>
- <xs:attributeGroup name="attlist.calculate">
- <xs:attribute type="xs:string" name="field" use="required">
- <xs:annotation><xs:documentation>The name (key) of the map (or env if map-name is empty) field to use.</xs:documentation></xs:annotation>
- </xs:attribute>
- <xs:attribute name="type" default="BigDecimal">
- <xs:simpleType>
- <xs:restriction base="xs:token">
- <xs:enumeration value="String"/>
- <xs:enumeration value="Double"/>
- <xs:enumeration value="Float"/>
- <xs:enumeration value="Long"/>
- <xs:enumeration value="Integer"/>
- <xs:enumeration value="BigDecimal"/>
- </xs:restriction>
- </xs:simpleType>
- </xs:attribute>
- <xs:attribute name="rounding-mode" default="HalfEven">
- <xs:annotation>
- <xs:documentation>
- Rounding mode for BigDecimal calculation, primarily for divide operation.
- </xs:documentation>
- </xs:annotation>
- <xs:simpleType>
- <xs:restriction base="xs:token">
- <xs:enumeration value="Ceiling"><xs:annotation><xs:documentation>Rounding mode to round towards positive infinity</xs:documentation></xs:annotation></xs:enumeration>
- <xs:enumeration value="Floor"><xs:annotation><xs:documentation>Rounding mode to round towards negative infinity</xs:documentation></xs:annotation></xs:enumeration>
- <xs:enumeration value="Up"><xs:annotation><xs:documentation>Rounding mode to round towards "nearest neighbor" unless both neighbors are equidistant, in which case round up</xs:documentation></xs:annotation></xs:enumeration>
- <xs:enumeration value="Down"><xs:annotation><xs:documentation>Rounding mode to round towards "nearest neighbor" unless both neighbors are equidistant, in which case round down</xs:documentation></xs:annotation></xs:enumeration>
- <xs:enumeration value="HalfUp"><xs:annotation><xs:documentation>Rounding mode to round towards "nearest neighbor" unless both neighbors are equidistant, in which case round up</xs:documentation></xs:annotation></xs:enumeration>
- <xs:enumeration value="HalfDown"><xs:annotation><xs:documentation>Rounding mode to round towards "nearest neighbor" unless both neighbors are equidistant, in which case round down</xs:documentation></xs:annotation></xs:enumeration>
- <xs:enumeration value="HalfEven"><xs:annotation><xs:documentation>Rounding mode to round towards the "nearest neighbor" unless both neighbors are equidistant, in which case, round towards the even neighbor</xs:documentation></xs:annotation></xs:enumeration>
- <xs:enumeration value="Unnecessary"><xs:annotation><xs:documentation>Rounding mode to assert that the requested operation has an exact result, hence no rounding is necessary</xs:documentation></xs:annotation></xs:enumeration>
- <xs:enumeration value="${roundingMode}"><xs:annotation><xs:documentation>Convention for variable name for this attribute, in cases where it is determined at run-time.</xs:documentation></xs:annotation></xs:enumeration>
- </xs:restriction>
- </xs:simpleType>
- </xs:attribute>
- <xs:attribute type="xs:string" name="decimal-scale" default="2">
- <xs:annotation><xs:documentation>Initial scale to use for the internal BigDecimal. Defaults to 2 for monetary calculations.</xs:documentation></xs:annotation>
- </xs:attribute>
- <xs:attribute type="xs:string" name="decimal-format"/>
- </xs:attributeGroup>
<xs:element name="calcop">
<xs:annotation>
<xs:documentation>
- The calcop tag has an operator: get, add, subtract, multiply, divide, and negative.
+ A basic arithmetic operation.
+ Supports these operations: get, add, subtract, multiply, divide, and negate.
So add, subtract, multiply, and divide are just the basic arithmetic operations.
</xs:documentation>
</xs:annotation>
<xs:complexType>
<xs:choice minOccurs="0" maxOccurs="unbounded">
- <xs:element ref="calcop"/>
- <xs:element ref="number"/>
+ <xs:element ref="calcop" />
+ <xs:element ref="number" />
</xs:choice>
- <xs:attributeGroup ref="attlist.calcop"/>
+ <xs:attribute name="operator" use="required">
+ <xs:simpleType>
+ <xs:restriction base="xs:token">
+ <xs:enumeration value="get">
+ <xs:annotation>
+ <xs:documentation>
+ Gets the positive value.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:enumeration>
+ <xs:enumeration value="add" />
+ <xs:enumeration value="subtract" />
+ <xs:enumeration value="multiply" />
+ <xs:enumeration value="divide" />
+ <xs:enumeration value="negative">
+ <xs:annotation>
+ <xs:documentation>
+ Negates the value.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:enumeration>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
+ <xs:attribute type="xs:string" name="field">
+ <xs:annotation>
+ <xs:documentation>
+ The name of the field to use.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
</xs:complexType>
</xs:element>
- <xs:attributeGroup name="attlist.calcop">
- <xs:attribute name="operator" use="required">
- <xs:simpleType>
- <xs:restriction base="xs:token">
- <xs:enumeration value="get">
- <xs:annotation>
- <xs:documentation>
- Gets the positive value.
- </xs:documentation>
- </xs:annotation>
- </xs:enumeration>
- <xs:enumeration value="add"/>
- <xs:enumeration value="subtract"/>
- <xs:enumeration value="multiply"/>
- <xs:enumeration value="divide"/>
- <xs:enumeration value="negative">
- <xs:annotation>
- <xs:documentation>
- Negates the value
- </xs:documentation>
- </xs:annotation>
- </xs:enumeration>
- </xs:restriction>
- </xs:simpleType>
- </xs:attribute>
- <xs:attribute type="xs:string" name="field">
- <xs:annotation>
- <xs:documentation>
- The name (key) of the map field to use.
- </xs:documentation>
- </xs:annotation>
- </xs:attribute>
- </xs:attributeGroup>
<xs:element name="number">
<xs:annotation>
<xs:documentation>
This is used to put a numeric constant (a number) into the calculation.
It has one attribute: value. This must be a properly formatted number or an error will result.
- May use flexible string.
</xs:documentation>
</xs:annotation>
<xs:complexType>
- <xs:attributeGroup ref="attlist.number"/>
+ <xs:attribute type="xs:string" name="value" use="required">
+ <xs:annotation>
+ <xs:documentation>
+ Literal or flexible string.
+ <br/><br/>
+ Required. Attribute types: constant, ${expression}.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
</xs:complexType>
</xs:element>
- <xs:attributeGroup name="attlist.number">
- <xs:attribute type="xs:string" name="value" use="required">
- <xs:annotation>
- <xs:documentation>
- Literal or flexible string.
- </xs:documentation>
- </xs:annotation>
- </xs:attribute>
- </xs:attributeGroup>
<xs:element name="set-calendar" substitutionGroup="EnvOperations">
<xs:annotation>
<xs:documentation>
@@ -4427,13 +4496,6 @@ under the License.
</xs:annotation>
<xs:complexType>
<xs:attribute ref="field" />
- <xs:attribute type="xs:string" name="from-field">
- <xs:annotation>
- <xs:documentation>
- Deprecated - use the from attribute.
- </xs:documentation>
- </xs:annotation>
- </xs:attribute>
<xs:attribute type="xs:string" name="from">
<xs:annotation>
<xs:documentation>
@@ -4445,6 +4507,13 @@ under the License.
</xs:documentation>
</xs:annotation>
</xs:attribute>
+ <xs:attribute type="xs:string" name="from-field">
+ <xs:annotation>
+ <xs:documentation>
+ Deprecated - use the from attribute.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
<xs:attribute type="xs:string" name="value">
<xs:annotation>
<xs:documentation>
@@ -4455,19 +4524,19 @@ under the License.
</xs:documentation>
</xs:annotation>
</xs:attribute>
- <xs:attribute type="xs:string" name="default-value">
+ <xs:attribute type="xs:string" name="default">
<xs:annotation>
<xs:documentation>
- Deprecated - use the default attribute.
+ A default value that is used when the from attribute evaluates to null or empty.
+ <br/><br/>
+ Optional. Attribute types: constant, ${expression}.
</xs:documentation>
</xs:annotation>
</xs:attribute>
- <xs:attribute type="xs:string" name="default">
+ <xs:attribute type="xs:string" name="default-value">
<xs:annotation>
<xs:documentation>
- A default value that is used when the from attribute evaluates to null or empty.
- <br/><br/>
- Optional. Attribute types: constant, ${expression}.
+ Deprecated - use the default attribute.
</xs:documentation>
</xs:annotation>
</xs:attribute>
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/MethodContext.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/MethodContext.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/MethodContext.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/MethodContext.java Sun Jun 17 09:21:27 2012
@@ -18,7 +18,6 @@
*******************************************************************************/
package org.ofbiz.minilang.method;
-import java.util.Iterator;
import java.util.Locale;
import java.util.Map;
import java.util.TimeZone;
@@ -35,37 +34,35 @@ import org.ofbiz.base.util.collections.F
import org.ofbiz.base.util.string.FlexibleStringExpander;
import org.ofbiz.entity.Delegator;
import org.ofbiz.entity.GenericValue;
-import org.ofbiz.minilang.SimpleMethod;
import org.ofbiz.security.Security;
import org.ofbiz.security.authz.Authorization;
import org.ofbiz.service.DispatchContext;
import org.ofbiz.service.LocalDispatcher;
/**
- * A single operation, does the specified operation on the given field
+ * A container for the Mini-language script engine state.
*/
-public class MethodContext implements Iterable<Map.Entry<String, Object>> {
+public final class MethodContext {
public static final int EVENT = 1;
public static final int SERVICE = 2;
- protected Authorization authz;
- protected DispatchContext ctx;
- protected Delegator delegator;
- protected LocalDispatcher dispatcher;
- protected Map<String, Object> env = FastMap.newInstance();
- protected ClassLoader loader;
- protected Locale locale;
- protected int methodType;
- protected Map<String, Object> parameters;
- protected HttpServletRequest request = null;
- protected HttpServletResponse response = null;
- protected Map<String, Object> results = null;
- protected Security security;
- protected TimeZone timeZone;
+ private Authorization authz;
+ private Delegator delegator;
+ private LocalDispatcher dispatcher;
+ private Map<String, Object> env = FastMap.newInstance();
+ private ClassLoader loader;
+ private Locale locale;
+ private int methodType;
+ private Map<String, Object> parameters;
+ private HttpServletRequest request = null;
+ private HttpServletResponse response = null;
+ private Map<String, Object> results = FastMap.newInstance();
+ private Security security;
+ private TimeZone timeZone;
private int traceCount = 0;
private int traceLogLevel = Debug.INFO;
- protected GenericValue userLogin;
+ private GenericValue userLogin;
public MethodContext(DispatchContext ctx, Map<String, ? extends Object> context, ClassLoader loader) {
this.methodType = MethodContext.SERVICE;
@@ -77,7 +74,6 @@ public class MethodContext implements It
this.delegator = ctx.getDelegator();
this.authz = ctx.getAuthorization();
this.security = ctx.getSecurity();
- this.results = FastMap.newInstance();
this.userLogin = (GenericValue) context.get("userLogin");
if (this.loader == null) {
try {
@@ -147,8 +143,6 @@ public class MethodContext implements It
if (this.userLogin == null)
this.userLogin = (GenericValue) this.request.getSession().getAttribute("userLogin");
}
- } else if (methodType == MethodContext.SERVICE) {
- this.results = FastMap.newInstance();
}
if (this.loader == null) {
try {
@@ -159,15 +153,6 @@ public class MethodContext implements It
}
}
- public String expandString(FlexibleStringExpander originalExdr) {
- return originalExdr.expandString(this.env);
- }
-
- /** Expands environment variables delimited with ${} */
- public String expandString(String original) {
- return FlexibleStringExpander.expandString(original, this.env);
- }
-
public Authorization getAuthz() {
return this.authz;
}
@@ -193,15 +178,11 @@ public class MethodContext implements It
* @return The environment value if found, otherwise null.
*/
public <T> T getEnv(String key) {
- String ekey = this.expandString(key);
+ String ekey = FlexibleStringExpander.expandString(key, this.env);
FlexibleMapAccessor<T> fma = FlexibleMapAccessor.getInstance(ekey);
return this.getEnv(fma);
}
- public Iterator<Map.Entry<String, Object>> getEnvEntryIterator() {
- return this.env.entrySet().iterator();
- }
-
public Map<String, Object> getEnvMap() {
return this.env;
}
@@ -262,10 +243,6 @@ public class MethodContext implements It
return this.traceCount > 0;
}
- public Iterator<Map.Entry<String, Object>> iterator() {
- return this.env.entrySet().iterator();
- }
-
/**
* Calls putEnv for each entry in the Map, thus allowing for the additional flexibility in naming supported in that method.
*/
@@ -290,7 +267,7 @@ public class MethodContext implements It
* The value to set in the named environment location.
*/
public <T> void putEnv(String key, T value) {
- String ekey = this.expandString(key);
+ String ekey = FlexibleStringExpander.expandString(key, this.env);
FlexibleMapAccessor<T> fma = FlexibleMapAccessor.getInstance(ekey);
this.putEnv(fma, value);
}
@@ -315,21 +292,11 @@ public class MethodContext implements It
* The name of the environment value to get. Can contain "." syntax elements as described above.
*/
public <T> T removeEnv(String key) {
- String ekey = this.expandString(key);
+ String ekey = FlexibleStringExpander.expandString(key, this.env);
FlexibleMapAccessor<T> fma = FlexibleMapAccessor.getInstance(ekey);
return this.removeEnv(fma);
}
- public void setErrorReturn(String errMsg, SimpleMethod simpleMethod) {
- if (getMethodType() == MethodContext.EVENT) {
- putEnv(simpleMethod.getEventErrorMessageName(), errMsg);
- putEnv(simpleMethod.getEventResponseCodeName(), simpleMethod.getDefaultErrorCode());
- } else if (getMethodType() == MethodContext.SERVICE) {
- putEnv(simpleMethod.getServiceErrorMessageName(), errMsg);
- putEnv(simpleMethod.getServiceResponseMessageName(), simpleMethod.getDefaultErrorCode());
- }
- }
-
public void setTraceOff() {
if (this.traceCount > 0) {
this.traceCount--;
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/MethodOperation.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/MethodOperation.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/MethodOperation.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/MethodOperation.java Sun Jun 17 09:21:27 2012
@@ -23,6 +23,7 @@ import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
+import org.ofbiz.base.util.string.FlexibleStringExpander;
import org.ofbiz.minilang.MiniLangElement;
import org.ofbiz.minilang.MiniLangException;
import org.ofbiz.minilang.SimpleMethod;
@@ -47,14 +48,18 @@ public abstract class MethodOperation ex
public abstract boolean exec(MethodContext methodContext) throws MiniLangException;
/** Create a string representation of the operation, using the current context.
- * <p><strong>Deprecated:</strong> No replacement.</p>
+ * @deprecated No replacement.
*/
- public abstract String expandedString(MethodContext methodContext);
+ public String expandedString(MethodContext methodContext) {
+ return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
+ }
/** Create a string representation of the operation - similar to the original XML.
- * <p><strong>Deprecated:</strong> Use {@link #toString()}.</p>
+ * @deprecated Use {@link #toString()}.
*/
- public abstract String rawString();
+ public String rawString() {
+ return toString();
+ }
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.TYPE)
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallBsh.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallBsh.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallBsh.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallBsh.java Sun Jun 17 09:21:27 2012
@@ -29,7 +29,6 @@ import org.ofbiz.base.util.StringUtil;
import org.ofbiz.base.util.UtilGenerics;
import org.ofbiz.base.util.UtilValidate;
import org.ofbiz.base.util.UtilXml;
-import org.ofbiz.base.util.string.FlexibleStringExpander;
import org.ofbiz.minilang.MiniLangException;
import org.ofbiz.minilang.MiniLangUtil;
import org.ofbiz.minilang.MiniLangValidate;
@@ -84,7 +83,7 @@ public final class CallBsh extends Metho
bsh.setClassLoader(methodContext.getLoader());
try {
// setup environment
- for (Map.Entry<String, Object> entry : methodContext) {
+ for (Map.Entry<String, Object> entry : methodContext.getEnvMap().entrySet()) {
bsh.set(entry.getKey(), entry.getValue());
}
// run external, from resource, first if resource specified
@@ -139,16 +138,6 @@ public final class CallBsh extends Metho
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<set ");
if (this.resource.length() > 0) {
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallClassMethod.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallClassMethod.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallClassMethod.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallClassMethod.java Sun Jun 17 09:21:27 2012
@@ -94,16 +94,6 @@ public final class CallClassMethod exten
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<call-class-method ");
if (!this.className.isEmpty()) {
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallObjectMethod.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallObjectMethod.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallObjectMethod.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallObjectMethod.java Sun Jun 17 09:21:27 2012
@@ -89,16 +89,6 @@ public final class CallObjectMethod exte
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<call-class-method ");
if (!this.objFieldFma.isEmpty()) {
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallScript.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallScript.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallScript.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallScript.java Sun Jun 17 09:21:27 2012
@@ -111,16 +111,6 @@ public final class CallScript extends Me
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<script ");
if (this.location != null && this.location.length() > 0) {
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallService.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallService.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallService.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallService.java Sun Jun 17 09:21:27 2012
@@ -70,7 +70,7 @@ public final class CallService extends M
private final List<ResultToRequest> resultToRequestList;
private final List<ResultToResult> resultToResultList;
private final List<ResultToSession> resultToSessionList;
- private final String serviceName;
+ private final FlexibleStringExpander serviceNameFse;
private final String successCode;
private final FlexibleMessage successPrefix;
private final FlexibleMessage successSuffix;
@@ -85,7 +85,7 @@ public final class CallService extends M
MiniLangValidate.requiredAttributes(simpleMethod, element, "service-name");
MiniLangValidate.childElements(simpleMethod, element, "error-prefix", "error-suffix", "success-prefix", "success-suffix", "message-prefix", "message-suffix", "default-message", "results-to-map", "result-to-field", "result-to-request", "result-to-session", "result-to-result");
}
- serviceName = element.getAttribute("service-name");
+ serviceNameFse = FlexibleStringExpander.getInstance(element.getAttribute("service-name"));
inMapFma = FlexibleMapAccessor.getInstance(element.getAttribute("in-map-name"));
includeUserLogin = !"false".equals(element.getAttribute("include-user-login"));
breakOnError = !"false".equals(element.getAttribute("break-on-error"));
@@ -167,7 +167,7 @@ public final class CallService extends M
if (methodContext.isTraceOn()) {
outputTraceMessage(methodContext, "Begin call-service.");
}
- String serviceName = methodContext.expandString(this.serviceName);
+ String serviceName = serviceNameFse.expandString(methodContext.getEnvMap());
String errorCode = this.errorCode;
if (errorCode.isEmpty()) {
errorCode = simpleMethod.getDefaultErrorCode();
@@ -364,24 +364,14 @@ public final class CallService extends M
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
- aic.addServiceName(this.serviceName);
- }
-
- @Override
- public String rawString() {
- return toString();
+ aic.addServiceName(this.serviceNameFse.toString());
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder("<call-service ");
- sb.append("service-name=\"").append(this.serviceName).append("\" ");
+ sb.append("service-name=\"").append(this.serviceNameFse).append("\" ");
if (!this.inMapFma.isEmpty()) {
sb.append("in-map-name=\"").append(this.inMapFma).append("\" ");
}
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallServiceAsynch.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallServiceAsynch.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallServiceAsynch.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallServiceAsynch.java Sun Jun 17 09:21:27 2012
@@ -108,21 +108,11 @@ public final class CallServiceAsynch ext
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
aic.addServiceName(this.serviceNameFse.toString());
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<call-service-asynch ");
sb.append("service-name=\"").append(this.serviceNameFse).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallSimpleMapProcessor.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallSimpleMapProcessor.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallSimpleMapProcessor.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallSimpleMapProcessor.java Sun Jun 17 09:21:27 2012
@@ -26,7 +26,6 @@ import javolution.util.FastMap;
import org.ofbiz.base.util.UtilXml;
import org.ofbiz.base.util.collections.FlexibleMapAccessor;
-import org.ofbiz.base.util.string.FlexibleStringExpander;
import org.ofbiz.minilang.MiniLangException;
import org.ofbiz.minilang.MiniLangValidate;
import org.ofbiz.minilang.SimpleMapProcessor;
@@ -102,16 +101,6 @@ public final class CallSimpleMapProcesso
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<call-map-processor ");
if (!this.processorName.isEmpty()) {
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallSimpleMethod.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallSimpleMethod.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallSimpleMethod.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/CallSimpleMethod.java Sun Jun 17 09:21:27 2012
@@ -27,17 +27,16 @@ import java.util.Map;
import javolution.util.FastMap;
import org.ofbiz.base.location.FlexibleLocation;
-import org.ofbiz.minilang.artifact.ArtifactInfoContext;
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.UtilValidate;
import org.ofbiz.base.util.UtilXml;
import org.ofbiz.base.util.collections.FlexibleMapAccessor;
-import org.ofbiz.base.util.string.FlexibleStringExpander;
import org.ofbiz.minilang.MiniLangException;
import org.ofbiz.minilang.MiniLangRuntimeException;
import org.ofbiz.minilang.MiniLangValidate;
import org.ofbiz.minilang.SimpleMethod;
import org.ofbiz.minilang.ValidationException;
+import org.ofbiz.minilang.artifact.ArtifactInfoContext;
import org.ofbiz.minilang.method.MethodContext;
import org.ofbiz.minilang.method.MethodOperation;
import org.w3c.dom.Element;
@@ -150,11 +149,6 @@ public final class CallSimpleMethod exte
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
SimpleMethod simpleMethodToCall;
try {
@@ -183,11 +177,6 @@ public final class CallSimpleMethod exte
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<call-simple-method ");
if (this.methodName.length() > 0) {
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/Return.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/Return.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/Return.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/Return.java Sun Jun 17 09:21:27 2012
@@ -54,16 +54,6 @@ public final class Return extends Method
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<return ");
if (!"success".equals(responseCodeFse.getOriginal())) {
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/SetServiceFields.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/SetServiceFields.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/SetServiceFields.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/callops/SetServiceFields.java Sun Jun 17 09:21:27 2012
@@ -112,21 +112,11 @@ public final class SetServiceFields exte
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
aic.addServiceName(this.serviceNameFse.toString());
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<set-service-fields ");
if (!this.serviceNameFse.isEmpty()) {
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/CompareCondition.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/CompareCondition.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/CompareCondition.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/CompareCondition.java Sun Jun 17 09:21:27 2012
@@ -133,11 +133,6 @@ public final class CompareCondition exte
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
if (this.subOps != null) {
for (MethodOperation method : this.subOps) {
@@ -172,11 +167,6 @@ public final class CompareCondition exte
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<if-compare ");
sb.append("field=\"").append(this.fieldFma).append("\" operator=\"").append(operator).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/CompareFieldCondition.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/CompareFieldCondition.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/CompareFieldCondition.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/CompareFieldCondition.java Sun Jun 17 09:21:27 2012
@@ -143,11 +143,6 @@ public final class CompareFieldCondition
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
if (this.subOps != null) {
for (MethodOperation method : this.subOps) {
@@ -185,11 +180,6 @@ public final class CompareFieldCondition
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<if-compare-field ");
sb.append("field=\"").append(this.fieldFma).append("\" operator=\"").append(operator).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/EmptyCondition.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/EmptyCondition.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/EmptyCondition.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/EmptyCondition.java Sun Jun 17 09:21:27 2012
@@ -87,11 +87,6 @@ public final class EmptyCondition extend
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
if (this.subOps != null) {
for (MethodOperation method : this.subOps) {
@@ -114,11 +109,6 @@ public final class EmptyCondition extend
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<if-empty ");
sb.append("field=\"").append(this.fieldFma).append("\"/>");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/HasPermissionCondition.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/HasPermissionCondition.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/HasPermissionCondition.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/HasPermissionCondition.java Sun Jun 17 09:21:27 2012
@@ -105,11 +105,6 @@ public final class HasPermissionConditio
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
if (this.subOps != null) {
for (MethodOperation method : this.subOps) {
@@ -134,11 +129,6 @@ public final class HasPermissionConditio
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<if-has-permission ");
if (!this.permissionFse.isEmpty()) {
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/MasterIf.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/MasterIf.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/MasterIf.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/MasterIf.java Sun Jun 17 09:21:27 2012
@@ -97,14 +97,6 @@ public final class MasterIf extends Meth
}
@Override
- public String expandedString(MethodContext methodContext) {
- // TODO: fill in missing details, if needed
- StringBuilder messageBuf = new StringBuilder();
- this.condition.prettyPrint(messageBuf, methodContext);
- return "<if><condition>" + messageBuf + "</condition></if>";
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
for (MethodOperation method : this.thenSubOps) {
method.gatherArtifactInfo(aic);
@@ -122,8 +114,10 @@ public final class MasterIf extends Meth
}
@Override
- public String rawString() {
- return expandedString(null);
+ public String toString() {
+ StringBuilder messageBuf = new StringBuilder();
+ this.condition.prettyPrint(messageBuf, null);
+ return "<if><condition>" + messageBuf + "</condition></if>";
}
/**
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/RegexpCondition.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/RegexpCondition.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/RegexpCondition.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/RegexpCondition.java Sun Jun 17 09:21:27 2012
@@ -109,11 +109,6 @@ public class RegexpCondition extends Met
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
if (this.subOps != null) {
for (MethodOperation method : this.subOps) {
@@ -139,11 +134,6 @@ public class RegexpCondition extends Met
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<if-regexp ");
sb.append("field=\"").append(this.fieldFma).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/ValidateMethodCondition.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/ValidateMethodCondition.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/ValidateMethodCondition.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/conditional/ValidateMethodCondition.java Sun Jun 17 09:21:27 2012
@@ -24,7 +24,6 @@ import java.util.List;
import org.ofbiz.base.util.UtilXml;
import org.ofbiz.base.util.collections.FlexibleMapAccessor;
-import org.ofbiz.base.util.string.FlexibleStringExpander;
import org.ofbiz.minilang.MiniLangException;
import org.ofbiz.minilang.MiniLangRuntimeException;
import org.ofbiz.minilang.MiniLangUtil;
@@ -113,11 +112,6 @@ public final class ValidateMethodConditi
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
if (this.subOps != null) {
for (MethodOperation method : this.subOps) {
@@ -132,9 +126,6 @@ public final class ValidateMethodConditi
}
public void prettyPrint(StringBuilder messageBuffer, MethodContext methodContext) {
- // allow methodContext to be null
- String methodName = methodContext == null ? this.methodName : methodContext.expandString(this.methodName);
- String className = methodContext == null ? this.className : methodContext.expandString(this.className);
messageBuffer.append("validate-method[");
messageBuffer.append(className);
messageBuffer.append(".");
@@ -149,11 +140,6 @@ public final class ValidateMethodConditi
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<if-validate-method ");
sb.append("field=\"").append(this.fieldFma).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/ClearCacheLine.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/ClearCacheLine.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/ClearCacheLine.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/ClearCacheLine.java Sun Jun 17 09:21:27 2012
@@ -62,16 +62,6 @@ public final class ClearCacheLine extend
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<clear-cache-line ");
sb.append("entity-name=\"").append(this.entityNameFse).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/ClearEntityCaches.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/ClearEntityCaches.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/ClearEntityCaches.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/ClearEntityCaches.java Sun Jun 17 09:21:27 2012
@@ -18,7 +18,6 @@
*******************************************************************************/
package org.ofbiz.minilang.method.entityops;
-import org.ofbiz.base.util.string.FlexibleStringExpander;
import org.ofbiz.minilang.MiniLangException;
import org.ofbiz.minilang.MiniLangValidate;
import org.ofbiz.minilang.SimpleMethod;
@@ -51,16 +50,6 @@ public final class ClearEntityCaches ext
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
return "<clear-entity-caches/>";
}
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/CloneValue.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/CloneValue.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/CloneValue.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/CloneValue.java Sun Jun 17 09:21:27 2012
@@ -19,7 +19,6 @@
package org.ofbiz.minilang.method.entityops;
import org.ofbiz.base.util.collections.FlexibleMapAccessor;
-import org.ofbiz.base.util.string.FlexibleStringExpander;
import org.ofbiz.entity.GenericValue;
import org.ofbiz.minilang.MiniLangException;
import org.ofbiz.minilang.MiniLangValidate;
@@ -58,16 +57,6 @@ public final class CloneValue extends Me
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<clone-value ");
sb.append("value-field=\"").append(this.valueFma).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/CreateValue.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/CreateValue.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/CreateValue.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/CreateValue.java Sun Jun 17 09:21:27 2012
@@ -20,7 +20,6 @@ package org.ofbiz.minilang.method.entity
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.collections.FlexibleMapAccessor;
-import org.ofbiz.base.util.string.FlexibleStringExpander;
import org.ofbiz.entity.GenericEntityException;
import org.ofbiz.entity.GenericValue;
import org.ofbiz.minilang.MiniLangException;
@@ -80,16 +79,6 @@ public final class CreateValue extends M
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<create-value ");
sb.append("value-field=\"").append(this.valueFma).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityAnd.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityAnd.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityAnd.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityAnd.java Sun Jun 17 09:21:27 2012
@@ -18,15 +18,14 @@
*******************************************************************************/
package org.ofbiz.minilang.method.entityops;
-import org.ofbiz.minilang.artifact.ArtifactInfoContext;
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.GeneralException;
-import org.ofbiz.base.util.string.FlexibleStringExpander;
import org.ofbiz.entity.Delegator;
import org.ofbiz.entity.finder.ByAndFinder;
import org.ofbiz.minilang.MiniLangException;
import org.ofbiz.minilang.MiniLangValidate;
import org.ofbiz.minilang.SimpleMethod;
+import org.ofbiz.minilang.artifact.ArtifactInfoContext;
import org.ofbiz.minilang.method.MethodContext;
import org.ofbiz.minilang.method.MethodOperation;
import org.w3c.dom.Element;
@@ -67,21 +66,11 @@ public final class EntityAnd extends Met
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
aic.addEntityName(this.finder.getEntityName());
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<entity-and ");
sb.append("entity-name=\"").append(this.finder.getEntityName()).append("\" />");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityCondition.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityCondition.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityCondition.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityCondition.java Sun Jun 17 09:21:27 2012
@@ -18,15 +18,14 @@
*******************************************************************************/
package org.ofbiz.minilang.method.entityops;
-import org.ofbiz.minilang.artifact.ArtifactInfoContext;
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.GeneralException;
-import org.ofbiz.base.util.string.FlexibleStringExpander;
import org.ofbiz.entity.Delegator;
import org.ofbiz.entity.finder.ByConditionFinder;
import org.ofbiz.minilang.MiniLangException;
import org.ofbiz.minilang.MiniLangValidate;
import org.ofbiz.minilang.SimpleMethod;
+import org.ofbiz.minilang.artifact.ArtifactInfoContext;
import org.ofbiz.minilang.method.MethodContext;
import org.ofbiz.minilang.method.MethodOperation;
import org.w3c.dom.Element;
@@ -67,21 +66,11 @@ public final class EntityCondition exten
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
aic.addEntityName(this.finder.getEntityName());
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<entity-condition ");
sb.append("entity-name=\"").append(this.finder.getEntityName()).append("\" />");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityCount.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityCount.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityCount.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityCount.java Sun Jun 17 09:21:27 2012
@@ -122,21 +122,11 @@ public final class EntityCount extends M
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
aic.addEntityName(entityNameFse.toString());
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<entity-count ");
sb.append("entity-name=\"").append(this.entityNameFse).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityData.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityData.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityData.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityData.java Sun Jun 17 09:21:27 2012
@@ -126,16 +126,6 @@ public final class EntityData extends Me
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<entity-data ");
sb.append("location=\"").append(this.locationFse).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityOne.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityOne.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityOne.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/EntityOne.java Sun Jun 17 09:21:27 2012
@@ -18,15 +18,14 @@
*******************************************************************************/
package org.ofbiz.minilang.method.entityops;
-import org.ofbiz.minilang.artifact.ArtifactInfoContext;
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.GeneralException;
-import org.ofbiz.base.util.string.FlexibleStringExpander;
import org.ofbiz.entity.Delegator;
import org.ofbiz.entity.finder.PrimaryKeyFinder;
import org.ofbiz.minilang.MiniLangException;
import org.ofbiz.minilang.MiniLangValidate;
import org.ofbiz.minilang.SimpleMethod;
+import org.ofbiz.minilang.artifact.ArtifactInfoContext;
import org.ofbiz.minilang.method.MethodContext;
import org.ofbiz.minilang.method.MethodOperation;
import org.w3c.dom.Element;
@@ -66,21 +65,11 @@ public final class EntityOne extends Met
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
aic.addEntityName(this.finder.getEntityName());
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<entity-one ");
sb.append("entity-name=\"").append(this.finder.getEntityName()).append("\" />");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/FilterListByAnd.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/FilterListByAnd.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/FilterListByAnd.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/FilterListByAnd.java Sun Jun 17 09:21:27 2012
@@ -22,7 +22,6 @@ import java.util.List;
import java.util.Map;
import org.ofbiz.base.util.collections.FlexibleMapAccessor;
-import org.ofbiz.base.util.string.FlexibleStringExpander;
import org.ofbiz.entity.GenericEntity;
import org.ofbiz.entity.util.EntityUtil;
import org.ofbiz.minilang.MiniLangException;
@@ -67,16 +66,6 @@ public final class FilterListByAnd exten
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<filter-list-by-and ");
sb.append("list=\"").append(this.listFma).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/FilterListByDate.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/FilterListByDate.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/FilterListByDate.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/FilterListByDate.java Sun Jun 17 09:21:27 2012
@@ -23,7 +23,6 @@ import java.util.List;
import org.ofbiz.base.util.UtilDateTime;
import org.ofbiz.base.util.collections.FlexibleMapAccessor;
-import org.ofbiz.base.util.string.FlexibleStringExpander;
import org.ofbiz.entity.GenericEntity;
import org.ofbiz.entity.util.EntityUtil;
import org.ofbiz.minilang.MiniLangException;
@@ -76,16 +75,6 @@ public final class FilterListByDate exte
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<filter-list-by-date ");
sb.append("list=\"").append(this.listFma).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/FindByAnd.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/FindByAnd.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/FindByAnd.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/FindByAnd.java Sun Jun 17 09:21:27 2012
@@ -99,21 +99,11 @@ public final class FindByAnd extends Met
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
aic.addEntityName(entityNameFse.toString());
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<find-by-and ");
sb.append("entity-name=\"").append(this.entityNameFse).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/FindByPrimaryKey.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/FindByPrimaryKey.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/FindByPrimaryKey.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/FindByPrimaryKey.java Sun Jun 17 09:21:27 2012
@@ -106,21 +106,11 @@ public final class FindByPrimaryKey exte
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
aic.addEntityName(entityNameFse.toString());
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<find-by-primary-key ");
sb.append("entity-name=\"").append(this.entityNameFse).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/GetRelated.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/GetRelated.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/GetRelated.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/GetRelated.java Sun Jun 17 09:21:27 2012
@@ -87,21 +87,11 @@ public final class GetRelated extends Me
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
aic.addEntityName(relationNameFse.toString());
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<get-related ");
sb.append("value-field=\"").append(this.valueFma).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/GetRelatedOne.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/GetRelatedOne.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/GetRelatedOne.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/GetRelatedOne.java Sun Jun 17 09:21:27 2012
@@ -78,21 +78,11 @@ public final class GetRelatedOne extends
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
aic.addEntityName(relationNameFse.toString());
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<get-related-one ");
sb.append("value-field=\"").append(this.valueFma).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/MakeNextSeqId.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/MakeNextSeqId.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/MakeNextSeqId.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/MakeNextSeqId.java Sun Jun 17 09:21:27 2012
@@ -85,16 +85,6 @@ public final class MakeNextSeqId extends
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<make-next-seq-id ");
sb.append("value-field=\"").append(this.valueFma).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/MakeValue.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/MakeValue.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/MakeValue.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/MakeValue.java Sun Jun 17 09:21:27 2012
@@ -65,21 +65,11 @@ public final class MakeValue extends Met
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
public void gatherArtifactInfo(ArtifactInfoContext aic) {
aic.addEntityName(entityNameFse.toString());
}
@Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<make-value ");
sb.append("entity-name=\"").append(this.entityNameFse).append("\" ");
Modified: ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/OrderValueList.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/OrderValueList.java?rev=1351078&r1=1351077&r2=1351078&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/OrderValueList.java (original)
+++ ofbiz/branches/jackrabbit20120501/framework/minilang/src/org/ofbiz/minilang/method/entityops/OrderValueList.java Sun Jun 17 09:21:27 2012
@@ -21,7 +21,6 @@ package org.ofbiz.minilang.method.entity
import java.util.List;
import org.ofbiz.base.util.collections.FlexibleMapAccessor;
-import org.ofbiz.base.util.string.FlexibleStringExpander;
import org.ofbiz.entity.GenericEntity;
import org.ofbiz.entity.util.EntityUtil;
import org.ofbiz.minilang.MiniLangException;
@@ -66,16 +65,6 @@ public final class OrderValueList extend
}
@Override
- public String expandedString(MethodContext methodContext) {
- return FlexibleStringExpander.expandString(toString(), methodContext.getEnvMap());
- }
-
- @Override
- public String rawString() {
- return toString();
- }
-
- @Override
public String toString() {
StringBuilder sb = new StringBuilder("<order-value-list ");
sb.append("list=\"").append(this.listFma).append("\" ");