ProductSearchContext productSearchContext = new ProductSearchContext(delegator, visitId);
List<ProductSearchConstraint> productSearchConstraintList = ProductSearchOptions.getConstraintList(session);
if (UtilValidate.isNotEmpty(productSearchConstraintList)) {
productSearchContext.addProductSearchConstraints(productSearchConstraintList);
}
productSearchContext.finishKeywordConstraints();
productSearchContext.finishCategoryAndFeatureConstraints();
DynamicViewEntity dynamicViewEntity = productSearchContext.dynamicViewEntity;
List<EntityCondition> entityConditionList = productSearchContext.entityConditionList;
List<String> fieldsToSelect = FastList.newInstance();