You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by nm...@apache.org on 2015/04/10 22:22:59 UTC
svn commit: r1672752 [9/18] - in /ofbiz/trunk:
applications/accounting/src/org/ofbiz/accounting/agreement/
applications/accounting/src/org/ofbiz/accounting/finaccount/
applications/accounting/src/org/ofbiz/accounting/invoice/
applications/accounting/sr...
Modified: ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyServices.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyServices.java?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyServices.java (original)
+++ ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyServices.java Fri Apr 10 20:22:54 2015
@@ -26,13 +26,12 @@ import java.nio.ByteBuffer;
import java.nio.charset.Charset;
import java.sql.Timestamp;
import java.util.Collection;
+import java.util.HashMap;
+import java.util.LinkedList;
import java.util.List;
import java.util.Locale;
import java.util.Map;
-import javolution.util.FastList;
-import javolution.util.FastMap;
-
import org.apache.commons.csv.CSVFormat;
import org.apache.commons.csv.CSVRecord;
import org.ofbiz.base.util.Debug;
@@ -106,10 +105,10 @@ public class PartyServices {
* @return Map with the result of the service, the output parameters.
*/
public static Map<String, Object> createPerson(DispatchContext ctx, Map<String, ? extends Object> context) {
- Map<String, Object> result = FastMap.newInstance();
+ Map<String, Object> result = new HashMap<String, Object>();
Delegator delegator = ctx.getDelegator();
Timestamp now = UtilDateTime.nowTimestamp();
- List<GenericValue> toBeStored = FastList.newInstance();
+ List<GenericValue> toBeStored = new LinkedList<GenericValue>();
Locale locale = (Locale) context.get("locale");
// in most cases userLogin will be null, but get anyway so we can keep track of that info if it is available
GenericValue userLogin = (GenericValue) context.get("userLogin");
@@ -279,7 +278,7 @@ public class PartyServices {
* @return Map with the result of the service, the output parameters.
*/
public static Map<String, Object> updatePerson(DispatchContext ctx, Map<String, ? extends Object> context) {
- Map<String, Object> result = FastMap.newInstance();
+ Map<String, Object> result = new HashMap<String, Object>();
Delegator delegator = ctx.getDelegator();
LocalDispatcher dispatcher = ctx.getDispatcher();
Locale locale = (Locale) context.get("locale");
@@ -351,7 +350,7 @@ public class PartyServices {
* @return Map with the result of the service, the output parameters.
*/
public static Map<String, Object> createPartyGroup(DispatchContext ctx, Map<String, ? extends Object> context) {
- Map<String, Object> result = FastMap.newInstance();
+ Map<String, Object> result = new HashMap<String, Object>();
Delegator delegator = ctx.getDelegator();
GenericValue userLogin = (GenericValue) context.get("userLogin");
Timestamp now = UtilDateTime.nowTimestamp();
@@ -457,7 +456,7 @@ public class PartyServices {
* @return Map with the result of the service, the output parameters.
*/
public static Map<String, Object> updatePartyGroup(DispatchContext ctx, Map<String, ? extends Object> context) {
- Map<String, Object> result = FastMap.newInstance();
+ Map<String, Object> result = new HashMap<String, Object>();
Delegator delegator = ctx.getDelegator();
LocalDispatcher dispatcher = ctx.getDispatcher();
Locale locale = (Locale) context.get("locale");
@@ -524,7 +523,7 @@ public class PartyServices {
* @return Map with the result of the service, the output parameters.
*/
public static Map<String, Object> createAffiliate(DispatchContext ctx, Map<String, ? extends Object> context) {
- Map<String, Object> result = FastMap.newInstance();
+ Map<String, Object> result = new HashMap<String, Object>();
Delegator delegator = ctx.getDelegator();
Locale locale = (Locale) context.get("locale");
Timestamp now = UtilDateTime.nowTimestamp();
@@ -643,7 +642,7 @@ public class PartyServices {
* @return Map with the result of the service, the output parameters.
*/
public static Map<String, Object> createPartyNote(DispatchContext dctx, Map<String, ? extends Object> context) {
- Map<String, Object> result = FastMap.newInstance();
+ Map<String, Object> result = new HashMap<String, Object>();
Delegator delegator = dctx.getDelegator();
LocalDispatcher dispatcher = dctx.getDispatcher();
GenericValue userLogin = (GenericValue) context.get("userLogin");
@@ -715,9 +714,9 @@ public class PartyServices {
* @return Map with the result of the service, the output parameters.
*/
public static Map<String, Object> getPartyFromExactEmail(DispatchContext dctx, Map<String, ? extends Object> context) {
- Map<String, Object> result = FastMap.newInstance();
+ Map<String, Object> result = new HashMap<String, Object>();
Delegator delegator = dctx.getDelegator();
- Collection<Map<String, GenericValue>> parties = FastList.newInstance();
+ Collection<Map<String, GenericValue>> parties = new LinkedList<Map<String,GenericValue>>();
String email = (String) context.get("email");
Locale locale = (Locale) context.get("locale");
@@ -753,9 +752,9 @@ public class PartyServices {
}
public static Map<String, Object> getPartyFromEmail(DispatchContext dctx, Map<String, ? extends Object> context) {
- Map<String, Object> result = FastMap.newInstance();
+ Map<String, Object> result = new HashMap<String, Object>();
Delegator delegator = dctx.getDelegator();
- Collection<Map<String, GenericValue>> parties = FastList.newInstance();
+ Collection<Map<String, GenericValue>> parties = new LinkedList<Map<String,GenericValue>>();
String email = (String) context.get("email");
Locale locale = (Locale) context.get("locale");
@@ -798,9 +797,9 @@ public class PartyServices {
*/
public static Map<String, Object> getPartyFromUserLogin(DispatchContext dctx, Map<String, ? extends Object> context) {
Debug.logWarning("Running the getPartyFromUserLogin Service...", module);
- Map<String, Object> result = FastMap.newInstance();
+ Map<String, Object> result = new HashMap<String, Object>();
Delegator delegator = dctx.getDelegator();
- Collection<Map<String, GenericValue>> parties = FastList.newInstance();
+ Collection<Map<String, GenericValue>> parties = new LinkedList<Map<String,GenericValue>>();
String userLoginId = (String) context.get("userLoginId");
Locale locale = (Locale) context.get("locale");
@@ -828,7 +827,7 @@ public class PartyServices {
"partyservices.cannot_get_party_entities_read",
UtilMisc.toMap("errMessage", e.getMessage()), locale));
}
- if (parties.size() > 0) {
+ if (UtilValidate.isNotEmpty(parties)) {
result.put("parties", parties);
}
return result;
@@ -841,9 +840,9 @@ public class PartyServices {
* @return Map with the result of the service, the output parameters.
*/
public static Map<String, Object> getPartyFromPerson(DispatchContext dctx, Map<String, ? extends Object> context) {
- Map<String, Object> result = FastMap.newInstance();
+ Map<String, Object> result = new HashMap<String, Object>();
Delegator delegator = dctx.getDelegator();
- Collection<Map<String, GenericValue>> parties = FastList.newInstance();
+ Collection<Map<String, GenericValue>> parties = new LinkedList<Map<String,GenericValue>>();
String firstName = (String) context.get("firstName");
String lastName = (String) context.get("lastName");
Locale locale = (Locale) context.get("locale");
@@ -891,9 +890,9 @@ public class PartyServices {
* @return Map with the result of the service, the output parameters.
*/
public static Map<String, Object> getPartyFromPartyGroup(DispatchContext dctx, Map<String, ? extends Object> context) {
- Map<String, Object> result = FastMap.newInstance();
+ Map<String, Object> result = new HashMap<String, Object>();
Delegator delegator = dctx.getDelegator();
- Collection<Map<String, GenericValue>> parties = FastList.newInstance();
+ Collection<Map<String, GenericValue>> parties = new LinkedList<Map<String,GenericValue>>();
String groupName = (String) context.get("groupName");
Locale locale = (Locale) context.get("locale");
@@ -928,7 +927,7 @@ public class PartyServices {
}
public static Map<String, Object> getPerson(DispatchContext dctx, Map<String, ? extends Object> context) {
- Map<String, Object> result = FastMap.newInstance();
+ Map<String, Object> result = new HashMap<String, Object>();
Delegator delegator = dctx.getDelegator();
String partyId = (String) context.get("partyId");
Locale locale = (Locale) context.get("locale");
@@ -948,7 +947,7 @@ public class PartyServices {
}
public static Map<String, Object> createRoleType(DispatchContext dctx, Map<String, ? extends Object> context) {
- Map<String, Object> result = FastMap.newInstance();
+ Map<String, Object> result = new HashMap<String, Object>();
Delegator delegator = dctx.getDelegator();
Locale locale = (Locale) context.get("locale");
GenericValue roleType = null;
@@ -1136,11 +1135,11 @@ public class PartyServices {
dynamicView.addRelation("many", "", "UserLogin", ModelKeyMap.makeKeyMapList("partyId"));
// define the main condition & expression list
- List<EntityCondition> andExprs = FastList.newInstance();
+ List<EntityCondition> andExprs = new LinkedList<EntityCondition>();
EntityCondition mainCond = null;
- List<String> orderBy = FastList.newInstance();
- List<String> fieldsToSelect = FastList.newInstance();
+ List<String> orderBy = new LinkedList<String>();
+ List<String> fieldsToSelect = new LinkedList<String>();
// fields we need to select; will be used to set distinct
fieldsToSelect.add("partyId");
fieldsToSelect.add("statusId");
@@ -1500,7 +1499,7 @@ public class PartyServices {
}
}
- if (partyList == null) partyList = FastList.newInstance();
+ if (partyList == null) partyList = new LinkedList<GenericValue>();
result.put("partyList", partyList);
result.put("partyListSize", Integer.valueOf(partyListSize));
result.put("paramList", paramList);
@@ -1882,8 +1881,8 @@ public class PartyServices {
String csvString = Charset.forName(encoding).decode(fileBytes).toString();
final BufferedReader csvReader = new BufferedReader(new StringReader(csvString));
CSVFormat fmt = CSVFormat.DEFAULT.withHeader();
- List<String> errMsgs = FastList.newInstance();
- List<String> newErrMsgs = FastList.newInstance();
+ List<String> errMsgs = new LinkedList<String>();
+ List<String> newErrMsgs = new LinkedList<String>();
String lastPartyId = null; // last partyId read from the csv file
String currentPartyId = null; // current partyId from the csv file
String newPartyId = null; // new to create/update partyId in the system
@@ -2099,7 +2098,7 @@ public class PartyServices {
partiesCreated++;
} else {
errMsgs.addAll(newErrMsgs);
- newErrMsgs = FastList.newInstance();
+ newErrMsgs = new LinkedList<String>();
}
}
@@ -2201,31 +2200,23 @@ public class PartyServices {
partyContactMechPurpose.put("contactMechId", newContactMechId);
result = dispatcher.runSync("createPartyContactMechPurpose", partyContactMechPurpose);
}
-
- lastPartyId = currentPartyId;
- errMsgs.addAll(newErrMsgs);
- newErrMsgs = FastList.newInstance();
+ lastPartyId = currentPartyId;
+ errMsgs.addAll(newErrMsgs);
+ newErrMsgs = new LinkedList<String>();
}
}
-
}
-
- }
- catch (GenericServiceException e) {
- Debug.logError(e, module);
+ } catch (GenericServiceException e) {
+ Debug.logError(e, module);
return ServiceUtil.returnError(e.getMessage());
- }
-
- catch (GenericEntityException e) {
- Debug.logError(e, module);
- return ServiceUtil.returnError(e.getMessage());
- }
-
- catch (IOException e) {
- Debug.logError(e, module);
+ } catch (GenericEntityException e) {
+ Debug.logError(e, module);
+ return ServiceUtil.returnError(e.getMessage());
+ } catch (IOException e) {
+ Debug.logError(e, module);
return ServiceUtil.returnError(e.getMessage());
}
-
+
if (errMsgs.size() > 0) {
return ServiceUtil.returnError(errMsgs);
}
Modified: ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyWorker.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyWorker.java?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyWorker.java (original)
+++ ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyWorker.java Fri Apr 10 20:22:54 2015
@@ -20,15 +20,14 @@
package org.ofbiz.party.party;
import java.sql.Timestamp;
+import java.util.HashMap;
+import java.util.LinkedList;
import java.util.List;
import java.util.Locale;
import java.util.Map;
import javax.servlet.ServletRequest;
-import javolution.util.FastList;
-import javolution.util.FastMap;
-
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.GeneralException;
import org.ofbiz.base.util.UtilFormatOut;
@@ -57,7 +56,7 @@ public class PartyWorker {
public static Map<String, GenericValue> getPartyOtherValues(ServletRequest request, String partyId, String partyAttr, String personAttr, String partyGroupAttr) {
Delegator delegator = (Delegator) request.getAttribute("delegator");
- Map<String, GenericValue> result = FastMap.newInstance();
+ Map<String, GenericValue> result = new HashMap<String, GenericValue>();
try {
GenericValue party = EntityQuery.use(delegator).from("Party").where("partyId", partyId).queryOne();
@@ -248,7 +247,7 @@ public class PartyWorker {
String stateProvinceGeoId, String postalCode, String postalCodeExt, String countryGeoId,
String firstName, String middleName, String lastName) throws GeneralException {
// return list
- List<GenericValue> returnList = FastList.newInstance();
+ List<GenericValue> returnList = new LinkedList<GenericValue>();
// address information
if (firstName == null || lastName == null) {
@@ -319,7 +318,7 @@ public class PartyWorker {
throw new IllegalArgumentException();
}
- List<EntityCondition> addrExprs = FastList.newInstance();
+ List<EntityCondition> addrExprs = new LinkedList<EntityCondition>();
if (stateProvinceGeoId != null) {
if ("**".equals(stateProvinceGeoId)) {
Debug.logWarning("Illegal state code passed!", module);
@@ -369,7 +368,7 @@ public class PartyWorker {
return addresses;
}
- List<GenericValue> validFound = FastList.newInstance();
+ List<GenericValue> validFound = new LinkedList<GenericValue>();
// check the address line
for (GenericValue address: addresses) {
// address 1 field
@@ -443,7 +442,7 @@ public class PartyWorker {
}
public static List<String> getAssociatedPartyIdsByRelationshipType(Delegator delegator, String partyIdFrom, String partyRelationshipTypeId) {
- List<GenericValue> partyList = FastList.newInstance();
+ List<GenericValue> partyList = new LinkedList<GenericValue>();
List<String> partyIds = null;
try {
EntityConditionList<EntityExpr> baseExprs = EntityCondition.makeCondition(UtilMisc.toList(
@@ -452,7 +451,7 @@ public class PartyWorker {
List<GenericValue> associatedParties = EntityQuery.use(delegator).from("PartyRelationship").where(baseExprs).cache(true).queryList();
partyList.addAll(associatedParties);
while (UtilValidate.isNotEmpty(associatedParties)) {
- List<GenericValue> currentAssociatedParties = FastList.newInstance();
+ List<GenericValue> currentAssociatedParties = new LinkedList<GenericValue>();
for (GenericValue associatedParty : associatedParties) {
EntityConditionList<EntityExpr> innerExprs = EntityCondition.makeCondition(UtilMisc.toList(
EntityCondition.makeCondition("partyIdFrom", associatedParty.get("partyIdTo")),
Modified: ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/communication/ListCommunications.groovy
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/communication/ListCommunications.groovy?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/communication/ListCommunications.groovy (original)
+++ ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/communication/ListCommunications.groovy Fri Apr 10 20:22:54 2015
@@ -20,8 +20,6 @@
import org.ofbiz.entity.condition.EntityOperator;
import org.ofbiz.entity.condition.EntityCondition;
-import javolution.util.FastList;
-
partyId = parameters.partyId;
context.partyId = partyId;
@@ -38,10 +36,10 @@ if (previousSort?.equals(sortField)) {
sortField = "-" + sortField;
}
-List eventExprs = FastList.newInstance();
+List eventExprs = [];
expr = EntityCondition.makeCondition("partyIdTo", EntityOperator.EQUALS, partyId);
eventExprs.add(expr);
-expr = EntityCondition.makeCondition("partyIdFrom", EntityOperator.EQUALS, "partyId");
+expr = EntityCondition.makeCondition("partyIdFrom", EntityOperator.EQUALS, partyId);
eventExprs.add(expr);
ecl = EntityCondition.makeCondition(eventExprs, EntityOperator.OR);
events = from("CommunicationEvent").where(ecl).orderBy(sortField).queryList();
Modified: ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/communication/getPartyEmailFromCommEventInfo.groovy
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/communication/getPartyEmailFromCommEventInfo.groovy?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/communication/getPartyEmailFromCommEventInfo.groovy (original)
+++ ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/communication/getPartyEmailFromCommEventInfo.groovy Fri Apr 10 20:22:54 2015
@@ -19,7 +19,6 @@
import org.ofbiz.base.util.*;
import org.ofbiz.entity.util.EntityUtil;
-import javolution.util.FastList;
communicationEvent = from("CommunicationEvent").where("communicationEventId", parameters.communicationEventId).cache(true).queryOne();
@@ -40,7 +39,7 @@ name = communicationEvent.note.substring
if (name) {
counter = 0;
lastBlank = 0;
- List names = FastList.newInstance();
+ List names = [];
while ((nextBlank = name.indexOf(" ", lastBlank)) != -1) {
names.add(name.substring(lastBlank, nextBlank));
lastBlank = nextBlank + 1;
Modified: ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/PartyFinancialHistory.groovy
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/PartyFinancialHistory.groovy?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/PartyFinancialHistory.groovy (original)
+++ ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/PartyFinancialHistory.groovy Fri Apr 10 20:22:54 2015
@@ -25,7 +25,6 @@ import org.ofbiz.accounting.payment.*;
import org.ofbiz.entity.*;
import org.ofbiz.entity.condition.*;
import org.ofbiz.entity.util.*;
-import javolution.util.FastMap;
Boolean actualCurrency = new Boolean(context.actualCurrency);
if (actualCurrency == null) {
Modified: ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/UnAppliedInvoicesForParty.groovy
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/UnAppliedInvoicesForParty.groovy?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/UnAppliedInvoicesForParty.groovy (original)
+++ ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/UnAppliedInvoicesForParty.groovy Fri Apr 10 20:22:54 2015
@@ -25,7 +25,6 @@ import org.ofbiz.accounting.payment.*;
import org.ofbiz.entity.*;
import org.ofbiz.entity.condition.*;
import org.ofbiz.entity.util.*;
-import javolution.util.FastMap;
Boolean actualCurrency = new Boolean(context.actualCurrency);
if (actualCurrency == null) {
Modified: ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/UnAppliedPaymentsForParty.groovy
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/UnAppliedPaymentsForParty.groovy?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/UnAppliedPaymentsForParty.groovy (original)
+++ ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/UnAppliedPaymentsForParty.groovy Fri Apr 10 20:22:54 2015
@@ -25,7 +25,6 @@ import org.ofbiz.accounting.payment.*;
import org.ofbiz.entity.*;
import org.ofbiz.entity.condition.*;
import org.ofbiz.entity.util.*;
-import javolution.util.FastMap;
Boolean actualCurrency = new Boolean(context.actualCurrency);
if (actualCurrency == null) {
Modified: ofbiz/trunk/applications/product/script/org/ofbiz/product/catalog/CatalogServices.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/script/org/ofbiz/product/catalog/CatalogServices.xml?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/script/org/ofbiz/product/catalog/CatalogServices.xml (original)
+++ ofbiz/trunk/applications/product/script/org/ofbiz/product/catalog/CatalogServices.xml Fri Apr 10 20:22:54 2015
@@ -449,7 +449,7 @@ under the License.
</entity-and>
<!-- Get all categories -->
- <call-class-method method-name="newInstance" class-name="javolution.util.FastList" ret-field="parameters.productCategories"/>
+ <set field="parameters.productCategories" value="${groovy: []}" type="List"/>
<iterate entry="prodCatalogCategory" list="prodCatalogCategoryList">
<set field="rootProductCategoryId" from-field="prodCatalogCategory.productCategoryId"/>
<entity-and list="productCategoryRollupList" entity-name="ProductCategoryRollup" filter-by-date="true">
Modified: ofbiz/trunk/applications/product/src/org/ofbiz/product/catalog/CatalogWorker.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/src/org/ofbiz/product/catalog/CatalogWorker.java?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/src/org/ofbiz/product/catalog/CatalogWorker.java (original)
+++ ofbiz/trunk/applications/product/src/org/ofbiz/product/catalog/CatalogWorker.java Fri Apr 10 20:22:54 2015
@@ -19,6 +19,7 @@
package org.ofbiz.product.catalog;
import java.util.Collection;
+import java.util.LinkedList;
import java.util.List;
import java.util.Map;
@@ -26,8 +27,6 @@ import javax.servlet.ServletRequest;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;
-import javolution.util.FastList;
-
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.StringUtil;
import org.ofbiz.base.util.UtilHttp;
@@ -69,7 +68,7 @@ public class CatalogWorker {
}
public static List<String> getAllCatalogIds(ServletRequest request) {
- List<String> catalogIds = FastList.newInstance();
+ List<String> catalogIds = new LinkedList<String>();
List<GenericValue> catalogs = null;
Delegator delegator = (Delegator) request.getAttribute("delegator");
try {
@@ -177,7 +176,7 @@ public class CatalogWorker {
if (!fromSession) {
if (Debug.verboseOn()) Debug.logVerbose("[CatalogWorker.getCurrentCatalogId] Setting new catalog name: " + prodCatalogId, module);
session.setAttribute("CURRENT_CATALOG_ID", prodCatalogId);
- CategoryWorker.setTrail(request, FastList.<String>newInstance());
+ CategoryWorker.setTrail(request, new LinkedList<String>());
}
return prodCatalogId;
}
@@ -195,8 +194,8 @@ public class CatalogWorker {
}
public static List<String> getCatalogIdsAvailable(List<GenericValue> partyCatalogs, List<GenericValue> storeCatalogs) {
- List<String> categoryIds = FastList.newInstance();
- List<GenericValue> allCatalogLinks = FastList.newInstance();
+ List<String> categoryIds = new LinkedList<String>();
+ List<GenericValue> allCatalogLinks = new LinkedList<GenericValue>();
if (partyCatalogs != null) allCatalogLinks.addAll(partyCatalogs);
if (storeCatalogs != null) allCatalogLinks.addAll(storeCatalogs);
@@ -387,7 +386,7 @@ public class CatalogWorker {
public static Collection<String> getCatalogQuickaddCategories(ServletRequest request, String prodCatalogId) {
if (prodCatalogId == null || prodCatalogId.length() <= 0) return null;
- Collection<String> categoryIds = FastList.newInstance();
+ Collection<String> categoryIds = new LinkedList<String>();
Collection<GenericValue> prodCatalogCategories = getProdCatalogCategories(request, prodCatalogId, "PCCT_QUICK_ADD");
Modified: ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CatalogUrlFilter.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CatalogUrlFilter.java?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CatalogUrlFilter.java (original)
+++ ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CatalogUrlFilter.java Fri Apr 10 20:22:54 2015
@@ -20,6 +20,7 @@ package org.ofbiz.product.category;
import java.io.IOException;
import java.util.Collections;
+import java.util.LinkedList;
import java.util.List;
import javax.servlet.FilterChain;
@@ -31,8 +32,6 @@ import javax.servlet.ServletResponse;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
-import javolution.util.FastList;
-
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.StringUtil;
import org.ofbiz.base.util.StringUtil.StringWrapper;
@@ -89,7 +88,7 @@ public class CatalogUrlFilter extends Co
try {
// look for productId
if (alternativeUrl.endsWith("-p")) {
- List<EntityCondition> productContentConds = FastList.newInstance();
+ List<EntityCondition> productContentConds = new LinkedList<EntityCondition>();
productContentConds.add(EntityCondition.makeCondition("productContentTypeId", "ALTERNATIVE_URL"));
productContentConds.add(EntityUtil.getFilterByDateExpr());
List<GenericValue> productContentInfos = EntityQuery.use(delegator).from("ProductContentAndInfo").where(productContentConds).orderBy("-fromDate").cache(true).queryList();
@@ -144,7 +143,7 @@ public class CatalogUrlFilter extends Co
// look for productCategoryId
if (alternativeUrl.endsWith("-c")) {
- List<EntityCondition> productCategoryContentConds = FastList.newInstance();
+ List<EntityCondition> productCategoryContentConds = new LinkedList<EntityCondition>();
productCategoryContentConds.add(EntityCondition.makeCondition("prodCatContentTypeId", "ALTERNATIVE_URL"));
productCategoryContentConds.add(EntityUtil.getFilterByDateExpr());
List<GenericValue> productCategoryContentInfos = EntityQuery.use(delegator).from("ProductCategoryContentAndInfo").where(productCategoryContentConds).orderBy("-fromDate").cache(true).queryList();
@@ -209,7 +208,7 @@ public class CatalogUrlFilter extends Co
if (UtilValidate.isNotEmpty(productId)) {
try {
- List<EntityCondition> conds = FastList.newInstance();
+ List<EntityCondition> conds = new LinkedList<EntityCondition>();
conds.add(EntityCondition.makeCondition("productId", productId));
conds.add(EntityUtil.getFilterByDateExpr());
List<GenericValue> productCategoryMembers = EntityQuery.use(delegator).select("productCategoryId").from("ProductCategoryMember").where(conds).orderBy("-fromDate").cache(true).queryList();
@@ -234,7 +233,7 @@ public class CatalogUrlFilter extends Co
// look for productCategoryId from productId
if (UtilValidate.isNotEmpty(productId)) {
try {
- List<EntityCondition> rolllupConds = FastList.newInstance();
+ List<EntityCondition> rolllupConds = new LinkedList<EntityCondition>();
rolllupConds.add(EntityCondition.makeCondition("productId", productId));
rolllupConds.add(EntityUtil.getFilterByDateExpr());
List<GenericValue> productCategoryMembers = EntityQuery.use(delegator).from("ProductCategoryMember").where(rolllupConds).orderBy("-fromDate").cache(true).queryList();
@@ -252,13 +251,13 @@ public class CatalogUrlFilter extends Co
// generate trail elements from productCategoryId
if (UtilValidate.isNotEmpty(productCategoryId)) {
- List<String> trailElements = FastList.newInstance();
+ List<String> trailElements = new LinkedList<String>();
trailElements.add(productCategoryId);
String parentProductCategoryId = productCategoryId;
while (UtilValidate.isNotEmpty(parentProductCategoryId)) {
// find product category rollup
try {
- List<EntityCondition> rolllupConds = FastList.newInstance();
+ List<EntityCondition> rolllupConds = new LinkedList<EntityCondition>();
rolllupConds.add(EntityCondition.makeCondition("productCategoryId", parentProductCategoryId));
rolllupConds.add(EntityUtil.getFilterByDateExpr());
List<GenericValue> productCategoryRollups = EntityQuery.use(delegator).from("ProductCategoryRollup").where(rolllupConds).orderBy("-fromDate").cache(true).queryList();
@@ -283,7 +282,7 @@ public class CatalogUrlFilter extends Co
List<String> trail = CategoryWorker.getTrail(httpRequest);
if (trail == null) {
- trail = FastList.newInstance();
+ trail = new LinkedList<String>();
}
// adjust trail
@@ -405,7 +404,7 @@ public class CatalogUrlFilter extends Co
url = urlBuilder.toString();
} else {
if (UtilValidate.isEmpty(trail)) {
- trail = FastList.newInstance();
+ trail = new LinkedList<String>();
}
url = CatalogUrlServlet.makeCatalogUrl(contextPath, trail, productId, productCategoryId, previousCategoryId);
}
@@ -448,7 +447,7 @@ public class CatalogUrlFilter extends Co
url = urlBuilder.toString();
} else {
if (UtilValidate.isEmpty(trail)) {
- trail = FastList.newInstance();
+ trail = new LinkedList<String>();
}
url = CatalogUrlServlet.makeCatalogUrl(contextPath, trail, productId, productCategoryId, previousCategoryId);
}
Modified: ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CatalogUrlServlet.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CatalogUrlServlet.java?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CatalogUrlServlet.java (original)
+++ ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CatalogUrlServlet.java Fri Apr 10 20:22:54 2015
@@ -19,6 +19,7 @@
package org.ofbiz.product.category;
import java.io.IOException;
+import java.util.LinkedList;
import java.util.List;
import javax.servlet.RequestDispatcher;
@@ -28,8 +29,6 @@ import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
-import javolution.util.FastList;
-
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.StringUtil;
import org.ofbiz.base.util.UtilValidate;
@@ -110,7 +109,7 @@ public class CatalogUrlServlet extends H
} else if (pathElements.size() > 2) {
List<String> trail = CategoryWorker.getTrail(request);
if (trail == null) {
- trail = FastList.newInstance();
+ trail = new LinkedList<String>();
}
if (trail.contains(pathElements.get(0))) {
Modified: ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CategoryContentWrapper.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CategoryContentWrapper.java?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CategoryContentWrapper.java (original)
+++ ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CategoryContentWrapper.java Fri Apr 10 20:22:54 2015
@@ -21,14 +21,13 @@ package org.ofbiz.product.category;
import java.io.IOException;
import java.io.StringWriter;
import java.io.Writer;
+import java.util.HashMap;
import java.util.List;
import java.util.Locale;
import java.util.Map;
import javax.servlet.http.HttpServletRequest;
-import javolution.util.FastMap;
-
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.GeneralException;
import org.ofbiz.base.util.StringUtil;
@@ -145,7 +144,7 @@ public class CategoryContentWrapper impl
GenericValue categoryContent = EntityUtil.getFirst(categoryContentList);
if (categoryContent != null) {
// when rendering the category content, always include the Product Category and ProductCategoryContent records that this comes from
- Map<String, Object> inContext = FastMap.newInstance();
+ Map<String, Object> inContext = new HashMap<String, Object>();
inContext.put("productCategory", productCategory);
inContext.put("categoryContent", categoryContent);
ContentWorker.renderContentAsText(dispatcher, delegator, categoryContent.getString("contentId"), outWriter, inContext, locale, mimeTypeId, null, null, true);
Modified: ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CategoryServices.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CategoryServices.java?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CategoryServices.java (original)
+++ ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CategoryServices.java Fri Apr 10 20:22:54 2015
@@ -19,6 +19,8 @@
package org.ofbiz.product.category;
import java.sql.Timestamp;
+import java.util.HashMap;
+import java.util.LinkedList;
import java.util.List;
import java.util.Locale;
import java.util.Map;
@@ -26,9 +28,6 @@ import java.util.Map;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
-import javolution.util.FastList;
-import javolution.util.FastMap;
-
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.GeneralException;
import org.ofbiz.base.util.UtilDateTime;
@@ -97,7 +96,7 @@ public class CategoryServices {
}
List<String> orderByFields = UtilGenerics.checkList(context.get("orderByFields"));
- if (orderByFields == null) orderByFields = FastList.newInstance();
+ if (orderByFields == null) orderByFields = new LinkedList<String>();
String entityName = getCategoryFindEntityName(delegator, orderByFields, introductionDateLimit, releaseDateLimit);
GenericValue productCategory;
@@ -112,7 +111,7 @@ public class CategoryServices {
if (activeOnly) {
productCategoryMembers = EntityUtil.filterByDate(productCategoryMembers, true);
}
- List<EntityCondition> filterConditions = FastList.newInstance();
+ List<EntityCondition> filterConditions = new LinkedList<EntityCondition>();
if (introductionDateLimit != null) {
EntityCondition condition = EntityCondition.makeCondition(EntityCondition.makeCondition("introductionDate", EntityOperator.EQUALS, null), EntityOperator.OR, EntityCondition.makeCondition("introductionDate", EntityOperator.LESS_THAN_EQUAL_TO, introductionDateLimit));
filterConditions.add(condition);
@@ -218,7 +217,7 @@ public class CategoryServices {
Timestamp releaseDateLimit = (Timestamp) context.get("releaseDateLimit");
List<String> orderByFields = UtilGenerics.checkList(context.get("orderByFields"));
- if (orderByFields == null) orderByFields = FastList.newInstance();
+ if (orderByFields == null) orderByFields = new LinkedList<String>();
String entityName = getCategoryFindEntityName(delegator, orderByFields, introductionDateLimit, releaseDateLimit);
String prodCatalogId = (String) context.get("prodCatalogId");
@@ -236,7 +235,6 @@ public class CategoryServices {
}
Timestamp nowTimestamp = UtilDateTime.nowTimestamp();
-
int viewIndex = 0;
try {
viewIndex = Integer.valueOf((String) context.get("viewIndexString")).intValue();
@@ -291,7 +289,7 @@ public class CategoryServices {
if (activeOnly) {
productCategoryMembers = EntityUtil.filterByDate(productCategoryMembers, true);
}
- List<EntityCondition> filterConditions = FastList.newInstance();
+ List<EntityCondition> filterConditions = new LinkedList<EntityCondition>();
if (introductionDateLimit != null) {
EntityCondition condition = EntityCondition.makeCondition(EntityCondition.makeCondition("introductionDate", EntityOperator.EQUALS, null), EntityOperator.OR, EntityCondition.makeCondition("introductionDate", EntityOperator.LESS_THAN_EQUAL_TO, introductionDateLimit));
filterConditions.add(condition);
@@ -335,7 +333,7 @@ public class CategoryServices {
highIndex = listSize;
}
} else {
- List<EntityCondition> mainCondList = FastList.newInstance();
+ List<EntityCondition> mainCondList = new LinkedList<EntityCondition>();
mainCondList.add(EntityCondition.makeCondition("productCategoryId", EntityOperator.EQUALS, productCategory.getString("productCategoryId")));
if (activeOnly) {
mainCondList.add(EntityCondition.makeCondition("fromDate", EntityOperator.LESS_THAN_EQUAL_TO, nowTimestamp));
@@ -357,7 +355,7 @@ public class CategoryServices {
if (limitView) {
if (viewProductCategoryId != null) {
// do manual checking to filter view allow
- productCategoryMembers = FastList.newInstance();
+ productCategoryMembers = new LinkedList<GenericValue>();
GenericValue nextValue;
int chunkSize = 0;
listSize = 0;
@@ -399,7 +397,7 @@ public class CategoryServices {
}
// null safety
if (productCategoryMembers == null) {
- productCategoryMembers = FastList.newInstance();
+ productCategoryMembers = new LinkedList<GenericValue>();
}
if (highIndex > listSize) {
@@ -414,7 +412,7 @@ public class CategoryServices {
}
}
- Map<String, Object> result = FastMap.newInstance();
+ Map<String, Object> result = new HashMap<String, Object>();
result.put("viewIndex", Integer.valueOf(viewIndex));
result.put("viewSize", Integer.valueOf(viewSize));
result.put("lowIndex", Integer.valueOf(lowIndex));
@@ -438,7 +436,7 @@ public class CategoryServices {
String hrefString2 = request.getParameter("hrefString2");
String entityName = null;
String primaryKeyName = null;
-
+
if (isCatalog.equals("true")) {
entityName = "ProdCatalog";
primaryKeyName = "prodCatalogId";
@@ -446,11 +444,11 @@ public class CategoryServices {
entityName = "ProductCategory";
primaryKeyName = "productCategoryId";
}
-
- List categoryList = FastList.newInstance();
+
+ List categoryList = new LinkedList();
List<GenericValue> childOfCats;
List<String> sortList = org.ofbiz.base.util.UtilMisc.toList("sequenceNum", "title");
-
+
try {
GenericValue category = EntityQuery.use(delegator).from(entityName).where(primaryKeyName, productCategoryId).queryOne();
if (UtilValidate.isNotEmpty(category)) {
@@ -472,50 +470,47 @@ public class CategoryServices {
catId = childOfCat.get("productCategoryId");
catNameField = "CATEGORY_NAME";
-
- Map josonMap = FastMap.newInstance();
+
+ Map josonMap = new HashMap();
List<GenericValue> childList = null;
-
+
// Get the child list of chosen category
childList = EntityQuery.use(delegator).from("ProductCategoryRollup").where("parentProductCategoryId", catId).filterByDate().queryList();
-
+
// Get the chosen category information for the categoryContentWrapper
GenericValue cate = EntityQuery.use(delegator).from("ProductCategory").where("productCategoryId",catId).queryOne();
-
+
// If chosen category's child exists, then put the arrow before category icon
if (UtilValidate.isNotEmpty(childList)) {
josonMap.put("state", "closed");
}
- Map dataMap = FastMap.newInstance();
- Map dataAttrMap = FastMap.newInstance();
+ Map dataMap = new HashMap();
+ Map dataAttrMap = new HashMap();
CategoryContentWrapper categoryContentWrapper = new CategoryContentWrapper(cate, request);
-
String title = null;
if (UtilValidate.isNotEmpty(categoryContentWrapper.get(catNameField))) {
- title = categoryContentWrapper.get(catNameField)+" "+"["+catId+"]";
+ title = new StringBuffer(categoryContentWrapper.get(catNameField).toString()).append(" [").append(catId).append("]").toString();
dataMap.put("title", title);
} else {
title = catId.toString();
dataMap.put("title", catId);
}
- dataAttrMap.put("onClick", onclickFunction + "('" + catId + additionParam + "')");
-
+ dataAttrMap.put("onClick", new StringBuffer(onclickFunction).append("('").append(catId).append(additionParam).append("')").toString());
+
String hrefStr = hrefString + catId;
if (UtilValidate.isNotEmpty(hrefString2)) {
hrefStr = hrefStr + hrefString2;
}
dataAttrMap.put("href", hrefStr);
-
dataMap.put("attr", dataAttrMap);
josonMap.put("data", dataMap);
- Map attrMap = FastMap.newInstance();
+ Map attrMap = new HashMap();
attrMap.put("id", catId);
attrMap.put("isCatalog", false);
attrMap.put("rel", "CATEGORY");
- josonMap.put("attr",attrMap);
- josonMap.put("sequenceNum",childOfCat.get("sequenceNum"));
- josonMap.put("title",title);
-
+ josonMap.put("attr", attrMap);
+ josonMap.put("sequenceNum", childOfCat.get("sequenceNum"));
+ josonMap.put("title", title);
categoryList.add(josonMap);
}
List<Map<Object, Object>> sortedCategoryList = UtilMisc.sortMaps(categoryList, sortList);
Modified: ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CategoryWorker.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CategoryWorker.java?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CategoryWorker.java (original)
+++ ofbiz/trunk/applications/product/src/org/ofbiz/product/category/CategoryWorker.java Fri Apr 10 20:22:54 2015
@@ -20,6 +20,7 @@ package org.ofbiz.product.category;
import java.util.Collection;
import java.util.Collections;
+import java.util.LinkedList;
import java.util.List;
import java.util.Locale;
import java.util.Map;
@@ -28,8 +29,6 @@ import javax.servlet.ServletRequest;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;
-import javolution.util.FastList;
-
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.UtilDateTime;
import org.ofbiz.base.util.UtilFormatOut;
@@ -87,7 +86,7 @@ public class CategoryWorker {
public static void getCategoriesWithNoParent(ServletRequest request, String attributeName) {
Delegator delegator = (Delegator) request.getAttribute("delegator");
- Collection<GenericValue> results = FastList.newInstance();
+ Collection<GenericValue> results = new LinkedList<GenericValue>();
try {
Collection<GenericValue> allCategories = EntityQuery.use(delegator).from("ProductCategory").queryList();
@@ -141,7 +140,7 @@ public class CategoryWorker {
}
public static List<GenericValue> getRelatedCategoriesRet(Delegator delegator, String attributeName, String parentId, boolean limitView, boolean excludeEmpty, boolean recursive) {
- List<GenericValue> categories = FastList.newInstance();
+ List<GenericValue> categories = new LinkedList<GenericValue>();
if (Debug.verboseOn()) Debug.logVerbose("[CategoryWorker.getRelatedCategories] ParentID: " + parentId, module);
@@ -231,12 +230,12 @@ public class CategoryWorker {
}
private static EntityCondition buildCountCondition(String fieldName, String fieldValue) {
- List<EntityCondition> orCondList = FastList.newInstance();
+ List<EntityCondition> orCondList = new LinkedList<EntityCondition>();
orCondList.add(EntityCondition.makeCondition("thruDate", EntityOperator.GREATER_THAN, UtilDateTime.nowTimestamp()));
orCondList.add(EntityCondition.makeCondition("thruDate", EntityOperator.EQUALS, null));
EntityCondition orCond = EntityCondition.makeCondition(orCondList, EntityOperator.OR);
- List<EntityCondition> andCondList = FastList.newInstance();
+ List<EntityCondition> andCondList = new LinkedList<EntityCondition>();
andCondList.add(EntityCondition.makeCondition("fromDate", EntityOperator.LESS_THAN, UtilDateTime.nowTimestamp()));
andCondList.add(EntityCondition.makeCondition(fieldName, EntityOperator.EQUALS, fieldValue));
andCondList.add(orCond);
@@ -266,7 +265,7 @@ public class CategoryWorker {
}
public static List<String> adjustTrail(List<String> origTrail, String currentCategoryId, String previousCategoryId) {
- List<String> trail = FastList.newInstance();
+ List<String> trail = new LinkedList<String>();
if (origTrail != null) {
trail.addAll(origTrail);
}
@@ -390,7 +389,7 @@ public class CategoryWorker {
}
public static List<GenericValue> filterProductsInCategory(Delegator delegator, List<GenericValue> valueObjects, String productCategoryId, String productIdFieldName) throws GenericEntityException {
- List<GenericValue> newList = FastList.newInstance();
+ List<GenericValue> newList = new LinkedList<GenericValue>();
if (productCategoryId == null) return newList;
if (valueObjects == null) return null;
@@ -443,13 +442,13 @@ public class CategoryWorker {
String productCategoryId = (String) context.get("productCategoryId");
Map<String, Object> results = ServiceUtil.returnSuccess();
Delegator delegator = dctx.getDelegator();
- List<String> trailElements = FastList.newInstance();
+ List<String> trailElements = new LinkedList<String>();
trailElements.add(productCategoryId);
String parentProductCategoryId = productCategoryId;
while (UtilValidate.isNotEmpty(parentProductCategoryId)) {
// find product category rollup
try {
- List<EntityCondition> rolllupConds = FastList.newInstance();
+ List<EntityCondition> rolllupConds = new LinkedList<EntityCondition>();
rolllupConds.add(EntityCondition.makeCondition("productCategoryId", parentProductCategoryId));
rolllupConds.add(EntityUtil.getFilterByDateExpr());
List<GenericValue> productCategoryRollups = EntityQuery.use(delegator).from("ProductCategoryRollup").where(rolllupConds).orderBy("sequenceNum").cache(true).queryList();
Modified: ofbiz/trunk/applications/product/src/org/ofbiz/product/category/SeoCatalogUrlServlet.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/src/org/ofbiz/product/category/SeoCatalogUrlServlet.java?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/src/org/ofbiz/product/category/SeoCatalogUrlServlet.java (original)
+++ ofbiz/trunk/applications/product/src/org/ofbiz/product/category/SeoCatalogUrlServlet.java Fri Apr 10 20:22:54 2015
@@ -19,6 +19,7 @@
package org.ofbiz.product.category;
import java.io.IOException;
+import java.util.LinkedList;
import java.util.List;
import javax.servlet.RequestDispatcher;
@@ -28,8 +29,6 @@ import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
-import javolution.util.FastList;
-
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.StringUtil;
import org.ofbiz.base.util.UtilMisc;
@@ -105,7 +104,7 @@ public class SeoCatalogUrlServlet extend
} else if (pathElements.size() > 2) {
List<String> trail = CategoryWorker.getTrail(request);
if (trail == null) {
- trail = FastList.newInstance();
+ trail = new LinkedList<String>();
}
if (trail.contains(pathElements.get(0))) {
Modified: ofbiz/trunk/applications/product/src/org/ofbiz/product/category/SeoConfigUtil.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/src/org/ofbiz/product/category/SeoConfigUtil.java?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/src/org/ofbiz/product/category/SeoConfigUtil.java (original)
+++ ofbiz/trunk/applications/product/src/org/ofbiz/product/category/SeoConfigUtil.java Fri Apr 10 20:22:54 2015
@@ -22,6 +22,8 @@ import java.io.FileInputStream;
import java.io.IOException;
import java.net.URL;
import java.util.HashMap;
+import java.util.HashSet;
+import java.util.LinkedList;
import java.util.List;
import java.util.Map;
import java.util.Set;
@@ -29,10 +31,6 @@ import java.util.Set;
import javax.servlet.http.HttpServletResponse;
import javax.xml.parsers.ParserConfigurationException;
-import javolution.util.FastList;
-import javolution.util.FastMap;
-import javolution.util.FastSet;
-
import org.apache.oro.text.regex.MalformedPatternException;
import org.apache.oro.text.regex.Pattern;
import org.apache.oro.text.regex.Perl5Compiler;
@@ -110,9 +108,9 @@ public class SeoConfigUtil {
seoReplacements = new HashMap<String, String>();
forwardReplacements = new HashMap<String, String>();
forwardResponseCodes = new HashMap<String, Integer>();
- userExceptionPatterns = FastList.newInstance();
- specialProductIds = FastMap.newInstance();
- charFilters = FastMap.newInstance();
+ userExceptionPatterns = new LinkedList<Pattern>();
+ specialProductIds = new HashMap<String, String>();
+ charFilters = new HashMap<String, String>();
try {
URL seoConfigFilename = UtilURL.fromResource(SEO_CONFIG_FILENAME);
Document configDoc = UtilXml.readXmlDocument(seoConfigFilename, false);
@@ -140,7 +138,7 @@ public class SeoConfigUtil {
if (categoryUrlEnabled) {
String allowedContextValue = UtilXml.childElementValue(categoryUrlElement, ELEMENT_ALLOWED_CONTEXT_PATHS, null);
- allowedContextPaths = FastSet.newInstance();
+ allowedContextPaths = new HashSet<String>();
if (UtilValidate.isNotEmpty(allowedContextValue)) {
List<String> allowedContextPathList = StringUtil.split(allowedContextValue, ALLOWED_CONTEXT_PATHS_SEPERATOR);
for (String path : allowedContextPathList) {
Modified: ofbiz/trunk/applications/product/src/org/ofbiz/product/category/SeoContentUrlFilter.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/src/org/ofbiz/product/category/SeoContentUrlFilter.java?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/src/org/ofbiz/product/category/SeoContentUrlFilter.java (original)
+++ ofbiz/trunk/applications/product/src/org/ofbiz/product/category/SeoContentUrlFilter.java Fri Apr 10 20:22:54 2015
@@ -20,6 +20,7 @@
package org.ofbiz.product.category;
import java.io.IOException;
+import java.util.LinkedList;
import java.util.List;
import java.util.Set;
@@ -32,8 +33,6 @@ import javax.servlet.ServletResponse;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
-import javolution.util.FastList;
-
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.UtilCodec;
import org.ofbiz.base.util.UtilHttp;
@@ -113,7 +112,7 @@ public class SeoContentUrlFilter extends
Delegator delegator = (Delegator) request.getAttribute("delegator");
String url = null;
try {
- List<EntityCondition> expr = FastList.newInstance();
+ List<EntityCondition> expr = new LinkedList<EntityCondition>();
expr.add(EntityCondition.makeCondition("caContentAssocTypeId", EntityOperator.EQUALS, "ALTERNATIVE_URL"));
expr.add(EntityCondition.makeCondition("caThruDate", EntityOperator.EQUALS, null));
expr.add(EntityCondition.makeCondition("contentIdStart", EntityOperator.EQUALS, contentId));
Modified: ofbiz/trunk/applications/product/src/org/ofbiz/product/category/SeoContextFilter.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/src/org/ofbiz/product/category/SeoContextFilter.java?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/src/org/ofbiz/product/category/SeoContextFilter.java (original)
+++ ofbiz/trunk/applications/product/src/org/ofbiz/product/category/SeoContextFilter.java Fri Apr 10 20:22:54 2015
@@ -23,6 +23,7 @@ import static org.ofbiz.base.util.UtilGe
import java.io.IOException;
import java.net.URL;
import java.util.Collection;
+import java.util.HashSet;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
@@ -38,8 +39,6 @@ import javax.servlet.ServletResponse;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
-import javolution.util.FastSet;
-
import org.apache.oro.text.regex.Pattern;
import org.apache.oro.text.regex.Perl5Matcher;
import org.ofbiz.base.util.Debug;
@@ -69,12 +68,12 @@ import org.ofbiz.webapp.website.WebSiteW
public class SeoContextFilter extends ContextFilter {
public static final String module = SeoContextFilter.class.getName();
-
- protected Set<String> WebServlets = FastSet.newInstance();
-
+
+ protected Set<String> WebServlets = new HashSet<String>();
+
public void init(FilterConfig config) throws ServletException {
super.init(config);
-
+
Map<String, ? extends ServletRegistration> servletRegistrations = config.getServletContext().getServletRegistrations();
for (String key : servletRegistrations.keySet()) {
Collection<String> servlets = servletRegistrations.get(key).getMappings();
Modified: ofbiz/trunk/applications/product/src/org/ofbiz/product/category/ftl/CatalogUrlSeoTransform.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/src/org/ofbiz/product/category/ftl/CatalogUrlSeoTransform.java?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/src/org/ofbiz/product/category/ftl/CatalogUrlSeoTransform.java (original)
+++ ofbiz/trunk/applications/product/src/org/ofbiz/product/category/ftl/CatalogUrlSeoTransform.java Fri Apr 10 20:22:54 2015
@@ -21,6 +21,8 @@ package org.ofbiz.product.category.ftl;
import java.io.IOException;
import java.io.Writer;
import java.util.Collection;
+import java.util.Hashtable;
+import java.util.LinkedList;
import java.util.List;
import java.util.Map;
@@ -29,9 +31,6 @@ import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
-import javolution.util.FastList;
-import javolution.util.FastMap;
-
import org.apache.oro.text.regex.MalformedPatternException;
import org.apache.oro.text.regex.Pattern;
import org.apache.oro.text.regex.Perl5Compiler;
@@ -187,8 +186,8 @@ public class CatalogUrlSeoTransform impl
public static synchronized void initCategoryMap(HttpServletRequest request, Delegator delegator) {
if (SeoConfigUtil.checkCategoryUrl()) {
- categoryNameIdMap = FastMap.newInstance();
- categoryIdNameMap = FastMap.newInstance();
+ categoryNameIdMap = new Hashtable<String, String>();
+ categoryIdNameMap = new Hashtable<String, String>();
Perl5Matcher matcher = new Perl5Matcher();
try {
@@ -556,7 +555,7 @@ public class CatalogUrlSeoTransform impl
String tempProductId = urlElements.get(i);
while (i >= 0) {
try {
- List<EntityExpr> exprs = FastList.newInstance();
+ List<EntityExpr> exprs = new LinkedList<EntityExpr>();
exprs.add(EntityCondition.makeCondition("productId", EntityOperator.EQUALS, lastPathElement));
// if (SeoConfigUtil.isSpecialProductId(tempProductId)) {
// exprs.add(EntityCondition.makeCondition("productId", EntityOperator.EQUALS, SeoConfigUtil.getSpecialProductId(tempProductId)));
Modified: ofbiz/trunk/applications/product/src/org/ofbiz/product/config/ProductConfigItemContentWrapper.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/src/org/ofbiz/product/config/ProductConfigItemContentWrapper.java?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/src/org/ofbiz/product/config/ProductConfigItemContentWrapper.java (original)
+++ ofbiz/trunk/applications/product/src/org/ofbiz/product/config/ProductConfigItemContentWrapper.java Fri Apr 10 20:22:54 2015
@@ -21,13 +21,13 @@ package org.ofbiz.product.config;
import java.io.IOException;
import java.io.StringWriter;
import java.io.Writer;
+import java.util.HashMap;
+import java.util.List;
import java.util.Locale;
import java.util.Map;
import javax.servlet.http.HttpServletRequest;
-import javolution.util.FastMap;
-
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.GeneralException;
import org.ofbiz.base.util.UtilHttp;
@@ -167,7 +167,7 @@ public class ProductConfigItemContentWra
.queryFirst();
if (productConfigItemContent != null) {
// when rendering the product config item content, always include the ProductConfigItem and ProdConfItemContent records that this comes from
- Map<String, Object> inContext = FastMap.newInstance();
+ Map<String, Object> inContext = new HashMap<String, Object>();
inContext.put("productConfigItem", productConfigItem);
inContext.put("productConfigItemContent", productConfigItemContent);
ContentWorker.renderContentAsText(dispatcher, delegator, productConfigItemContent.getString("contentId"), outWriter, inContext, locale, mimeTypeId, null, null, false);
Modified: ofbiz/trunk/applications/product/src/org/ofbiz/product/config/ProductConfigWorker.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/src/org/ofbiz/product/config/ProductConfigWorker.java?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/src/org/ofbiz/product/config/ProductConfigWorker.java (original)
+++ ofbiz/trunk/applications/product/src/org/ofbiz/product/config/ProductConfigWorker.java Fri Apr 10 20:22:54 2015
@@ -18,6 +18,7 @@
*******************************************************************************/
package org.ofbiz.product.config;
+import java.util.LinkedList;
import java.util.List;
import java.util.Locale;
import java.util.Map;
@@ -25,8 +26,6 @@ import java.util.Enumeration;
import javax.servlet.http.HttpServletRequest;
-import javolution.util.FastList;
-
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.UtilGenerics;
import org.ofbiz.base.util.UtilHttp;
@@ -142,7 +141,7 @@ public class ProductConfigWorker {
if (ProductWorker.isVirtual((Delegator)request.getAttribute("delegator"), selectedProductId)) {
if ("VV_FEATURETREE".equals(ProductWorker.getProductVirtualVariantMethod((Delegator)request.getAttribute("delegator"), selectedProductId))) {
// get the selected features
- List<String> selectedFeatures = FastList.newInstance();
+ List<String> selectedFeatures = new LinkedList<String>();
Enumeration<String> paramNames = UtilGenerics.cast(request.getParameterNames());
while (paramNames.hasMoreElements()) {
String paramName = paramNames.nextElement();
@@ -189,12 +188,12 @@ public class ProductConfigWorker {
if (configWrapper == null || (!configWrapper.isCompleted())) return;
String configId = null;
List<ConfigItem> questions = configWrapper.getQuestions();
- List<GenericValue> configsToCheck = FastList.newInstance();
+ List<GenericValue> configsToCheck = new LinkedList<GenericValue>();
int selectedOptionSize = 0;
for (ConfigItem ci: questions) {
String configItemId = null;
Long sequenceNum = null;
- List<ProductConfigWrapper.ConfigOption> selectedOptions = FastList.newInstance();
+ List<ProductConfigWrapper.ConfigOption> selectedOptions = new LinkedList<ProductConfigWrapper.ConfigOption>();
List<ConfigOption> options = ci.getOptions();
if (ci.isStandard()) {
selectedOptions.addAll(options);
@@ -243,7 +242,7 @@ public class ProductConfigWorker {
for (ConfigItem ci: questions) {
String configItemId = null;
Long sequenceNum = null;
- List<ProductConfigWrapper.ConfigOption> selectedOptions = FastList.newInstance();
+ List<ProductConfigWrapper.ConfigOption> selectedOptions = new LinkedList<ProductConfigWrapper.ConfigOption>();
List<ConfigOption> options = ci.getOptions();
if (ci.isStandard()) {
selectedOptions.addAll(options);
@@ -309,7 +308,7 @@ public class ProductConfigWorker {
for (ConfigItem ci: questions) {
String configItemId = null;
Long sequenceNum = null;
- List<ProductConfigWrapper.ConfigOption> selectedOptions = FastList.newInstance();
+ List<ProductConfigWrapper.ConfigOption> selectedOptions = new LinkedList<ProductConfigWrapper.ConfigOption>();
List<ConfigOption> options = ci.getOptions();
if (ci.isStandard()) {
selectedOptions.addAll(options);
@@ -330,7 +329,7 @@ public class ProductConfigWorker {
configItemId = ci.getConfigItemAssoc().getString("configItemId");
sequenceNum = ci.getConfigItemAssoc().getLong("sequenceNum");
for (ConfigOption oneOption: selectedOptions) {
- List<GenericValue> toBeStored = FastList.newInstance();
+ List<GenericValue> toBeStored = new LinkedList<GenericValue>();
String configOptionId = oneOption.configOption.getString("configOptionId");
String description = oneOption.getComments();
GenericValue productConfigConfig = delegator.makeValue("ProductConfigConfig");
Modified: ofbiz/trunk/applications/product/src/org/ofbiz/product/config/ProductConfigWrapper.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/src/org/ofbiz/product/config/ProductConfigWrapper.java?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/src/org/ofbiz/product/config/ProductConfigWrapper.java (original)
+++ ofbiz/trunk/applications/product/src/org/ofbiz/product/config/ProductConfigWrapper.java Fri Apr 10 20:22:54 2015
@@ -22,15 +22,14 @@ package org.ofbiz.product.config;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.LinkedList;
import java.util.List;
import java.util.Locale;
import java.util.Map;
import java.util.Set;
-import javolution.util.FastList;
-import javolution.util.FastMap;
-import javolution.util.FastSet;
-
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.UtilMisc;
import org.ofbiz.base.util.UtilValidate;
@@ -42,7 +41,6 @@ import org.ofbiz.entity.util.EntityQuery
import org.ofbiz.service.LocalDispatcher;
import org.ofbiz.service.ServiceContainer;
-
/**
* Product Config Wrapper: gets product config to display
*/
@@ -80,7 +78,7 @@ public class ProductConfigWrapper implem
listPrice = pcw.listPrice;
basePrice = pcw.basePrice;
defaultPrice = pcw.defaultPrice;
- questions = FastList.newInstance();
+ questions = new LinkedList<ProductConfigWrapper.ConfigItem>();
delegator = pcw.getDelegator();
delegatorName = delegator.getDelegatorName();
dispatcher = pcw.getDispatcher();
@@ -122,10 +120,10 @@ public class ProductConfigWrapper implem
if (price != null) {
basePrice = price;
}
- questions = FastList.newInstance();
+ questions = new LinkedList<ProductConfigWrapper.ConfigItem>();
if ("AGGREGATED".equals(product.getString("productTypeId")) || "AGGREGATED_SERVICE".equals(product.getString("productTypeId"))) {
List<GenericValue> questionsValues = EntityQuery.use(delegator).from("ProductConfig").where("productId", productId).orderBy("sequenceNum").filterByDate().queryList();
- Set<String> itemIds = FastSet.newInstance();
+ Set<String> itemIds = new HashSet<String>();
for (GenericValue questionsValue: questionsValues) {
ConfigItem oneQuestion = new ConfigItem(questionsValue);
oneQuestion.setContent(locale, "text/html"); // TODO: mime-type shouldn't be hardcoded
@@ -285,18 +283,17 @@ public class ProductConfigWrapper implem
GenericValue oneComponent = components.get(component);
if (theOption.isVirtualComponent(oneComponent)) {
if (theOption.componentOptions == null) {
- theOption.componentOptions = FastMap.newInstance();
+ theOption.componentOptions = new HashMap<String, String>();
}
theOption.componentOptions.put(oneComponent.getString("productId"), componentOption);
// recalculate option price
theOption.recalculateOptionPrice(this);
-
}
}
public List<ConfigOption> getSelectedOptions() {
- List<ConfigOption> selectedOptions = FastList.newInstance();
+ List<ConfigOption> selectedOptions = new LinkedList<ProductConfigWrapper.ConfigOption>();
for (ConfigItem ci: questions) {
if (ci.isStandard()) {
selectedOptions.addAll(ci.getOptions());
@@ -312,7 +309,7 @@ public class ProductConfigWrapper implem
}
public List<ConfigOption> getDefaultOptions() {
- List<ConfigOption> defaultOptions = FastList.newInstance();
+ List<ConfigOption> defaultOptions = new LinkedList<ProductConfigWrapper.ConfigOption>();
for (ConfigItem ci: questions) {
ConfigOption co = ci.getDefault();
if (co != null) {
@@ -397,13 +394,13 @@ public class ProductConfigWrapper implem
public ConfigItem(GenericValue questionAssoc) throws Exception {
configItemAssoc = questionAssoc;
configItem = configItemAssoc.getRelatedOne("ConfigItemProductConfigItem", false);
- options = FastList.newInstance();
+ options = new LinkedList<ProductConfigWrapper.ConfigOption>();
}
public ConfigItem(ConfigItem ci) {
configItem = GenericValue.create(ci.configItem);
configItemAssoc = GenericValue.create(ci.configItemAssoc);
- options = FastList.newInstance();
+ options = new LinkedList<ProductConfigWrapper.ConfigOption>();
for (ConfigOption co: ci.options) {
options.add(new ConfigOption(co));
}
@@ -602,7 +599,7 @@ public class ProductConfigWrapper implem
public ConfigOption(ConfigOption co) {
configOption = GenericValue.create(co.configOption);
- componentList = FastList.newInstance();
+ componentList = new LinkedList<GenericValue>();
for (GenericValue component: co.componentList) {
componentList.add(GenericValue.create(component));
}
Modified: ofbiz/trunk/applications/product/src/org/ofbiz/product/feature/ParametricSearch.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/src/org/ofbiz/product/feature/ParametricSearch.java?rev=1672752&r1=1672751&r2=1672752&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/src/org/ofbiz/product/feature/ParametricSearch.java (original)
+++ ofbiz/trunk/applications/product/src/org/ofbiz/product/feature/ParametricSearch.java Fri Apr 10 20:22:54 2015
@@ -18,6 +18,9 @@
*******************************************************************************/
package org.ofbiz.product.feature;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.LinkedList;
import java.util.List;
import java.util.Map;
import java.util.Set;
@@ -25,10 +28,6 @@ import java.util.Set;
import javax.servlet.ServletRequest;
import javax.servlet.http.HttpServletRequest;
-import javolution.util.FastList;
-import javolution.util.FastMap;
-import javolution.util.FastSet;
-
import org.ofbiz.base.util.Debug;
import org.ofbiz.base.util.UtilHttp;
import org.ofbiz.base.util.UtilMisc;
@@ -62,7 +61,7 @@ public class ParametricSearch {
}
public static Map<String, List<GenericValue>> makeCategoryFeatureLists(String productCategoryId, Delegator delegator, int perTypeMaxSize) {
- Map<String, Map<String, GenericValue>> productFeaturesByTypeMap = FastMap.newInstance();
+ Map<String, Map<String, GenericValue>> productFeaturesByTypeMap = new HashMap<String, Map<String,GenericValue>>();
try {
List<GenericValue> productFeatureCategoryAppls = EntityQuery.use(delegator).from("ProductFeatureCategoryAppl").where("productCategoryId", productCategoryId).cache(true).queryList();
productFeatureCategoryAppls = EntityUtil.filterByDate(productFeatureCategoryAppls, true);
@@ -73,7 +72,7 @@ public class ParametricSearch {
String productFeatureTypeId = productFeature.getString("productFeatureTypeId");
Map<String, GenericValue> featuresByType = productFeaturesByTypeMap.get(productFeatureTypeId);
if (featuresByType == null) {
- featuresByType = FastMap.newInstance();
+ featuresByType = new HashMap<String, GenericValue>();
productFeaturesByTypeMap.put(productFeatureTypeId, featuresByType);
}
if (featuresByType.size() < perTypeMaxSize) {
@@ -98,7 +97,7 @@ public class ParametricSearch {
String productFeatureTypeId = productFeature.getString("productFeatureTypeId");
Map<String, GenericValue> featuresByType = productFeaturesByTypeMap.get(productFeatureTypeId);
if (featuresByType == null) {
- featuresByType = FastMap.newInstance();
+ featuresByType = new HashMap<String, GenericValue>();
productFeaturesByTypeMap.put(productFeatureTypeId, featuresByType);
}
if (featuresByType.size() < perTypeMaxSize) {
@@ -112,7 +111,7 @@ public class ParametricSearch {
}
// now before returning, order the features in each list by description
- Map<String, List<GenericValue>> productFeaturesByTypeMapSorted = FastMap.newInstance();
+ Map<String, List<GenericValue>> productFeaturesByTypeMapSorted = new HashMap<String, List<GenericValue>>();
for (Map.Entry<String, Map<String, GenericValue>> entry: productFeaturesByTypeMap.entrySet()) {
List<GenericValue> sortedFeatures = EntityUtil.orderBy(entry.getValue().values(), UtilMisc.toList("description","defaultSequenceNum"));
productFeaturesByTypeMapSorted.put(entry.getKey(), sortedFeatures);
@@ -125,16 +124,16 @@ public class ParametricSearch {
return getAllFeaturesByType(delegator, DEFAULT_PER_TYPE_MAX_SIZE);
}
public static Map<String, List<GenericValue>> getAllFeaturesByType(Delegator delegator, int perTypeMaxSize) {
- Map<String, List<GenericValue>> productFeaturesByTypeMap = FastMap.newInstance();
+ Map<String, List<GenericValue>> productFeaturesByTypeMap = new HashMap<String, List<GenericValue>>();
try {
- Set<String> typesWithOverflowMessages = FastSet.newInstance();
+ Set<String> typesWithOverflowMessages = new HashSet<String>();
EntityListIterator productFeatureEli = EntityQuery.use(delegator).from("ProductFeature").orderBy("description").queryIterator();
GenericValue productFeature = null;
while ((productFeature = productFeatureEli.next()) != null) {
String productFeatureTypeId = productFeature.getString("productFeatureTypeId");
List<GenericValue> featuresByType = productFeaturesByTypeMap.get(productFeatureTypeId);
if (featuresByType == null) {
- featuresByType = FastList.newInstance();
+ featuresByType = new LinkedList<GenericValue>();
productFeaturesByTypeMap.put(productFeatureTypeId, featuresByType);
}
if (featuresByType.size() > perTypeMaxSize) {
@@ -160,7 +159,7 @@ public class ParametricSearch {
/** Handles parameters coming in prefixed with "pft_" where the text in the key following the prefix is a productFeatureTypeId and the value is a productFeatureId; meant to be used with drop-downs and such */
public static Map<String, String> makeFeatureIdByTypeMap(Map<String, Object> parameters) {
- Map<String, String> featureIdByType = FastMap.newInstance();
+ Map<String, String> featureIdByType = new HashMap<String, String>();
if (parameters == null) return featureIdByType;
@@ -180,7 +179,7 @@ public class ParametricSearch {
/** Handles parameters coming in prefixed with "SEARCH_FEAT" where the parameter value is a productFeatureId; meant to be used with text entry boxes or check-boxes and such */
public static List<String> makeFeatureIdListFromPrefixed(Map<String, Object> parameters) {
- List<String> featureIdList = FastList.newInstance();
+ List<String> featureIdList = new LinkedList<String>();
if (parameters == null) return featureIdList;
for (Map.Entry<String, Object> entry: parameters.entrySet()) {
@@ -222,7 +221,7 @@ public class ParametricSearch {
* meant to be used with text entry boxes or check-boxes and such
**/
public static List<String> makeProductFeatureCategoryIdListFromPrefixed(Map<String, Object> parameters) {
- List<String> prodFeatureCategoryIdList = FastList.newInstance();
+ List<String> prodFeatureCategoryIdList = new LinkedList<String>();
if (parameters == null) return prodFeatureCategoryIdList;
for (Map.Entry<String, Object> entry: parameters.entrySet()) {