| java.lang.Object org.kuali.core.lookup.LookupUtils
LookupUtils | public class LookupUtils (Code) | | This is a static utility class for Lookup related utilities and helper methods.
|
Method Summary | |
public static void | applySearchResultsLimit(Criteria criteria, KualiDBPlatform platform) | public static String | convertReferencesToSelectCollectionToString(Collection<String> referencesToRefresh) | public static String | convertSetOfObjectIdsToString(Set<String> objectIds) | public static Set<String> | convertStringOfObjectIdsToSet(String objectIdsString) | public static Comparator | findBestValueComparatorForColumn(List<ResultRow> resultTable, int column) | public static String | forceUppercase(Class boClass, String fieldName, String fieldValue) This method uses the DataDictionary to determine whether to force uppercase the value, and if it should, then it does the
uppercase, and returns the upper-cased value.
Parameters: boClass - Parent BO class that the fieldName is a member of. Parameters: fieldName - Name of the field to be forced to uppercase. Parameters: fieldValue - Value of the field that may be uppercased. | public static Map<String, String> | forceUppercase(Class boClass, Map<String, String> fieldValues) This method uses the DataDictionary to determine whether to force uppercase the values, and if it should, then it does the
uppercase, and returns the upper-cased Map of fieldname/fieldValue pairs.
Parameters: boClass - Parent BO class that the fieldName is a member of. Parameters: fieldValues - A Map where the key is the fieldName and the value is the fieldValue. | public static Map<String, String> | generateCompositeSelectedObjectIds(Set<String> previouslySelectedObjectIds, Set<String> displayedObjectIds, Set<String> selectedObjectIds) Given 3 sets of object IDs: the set of selected object IDs before rendering the current page,
the set of object IDs rendered on the page, and the set of object IDs selected on the page, computes
the total set of selected object IDs. | public static Integer | getApplicationMaximumSearchResulsPerPageForMultipleValueLookups() | public static Integer | getApplicationSearchResultsLimit() | public static BusinessObject | getNestedBusinessObject(BusinessObject bo, String attributeName) | public static Class | getNestedReferenceClass(BusinessObject businessObject, String attributeName) | public static Map | getPrimitiveReference(BusinessObject businessObject, String attributeName) | public static void | removeHiddenCriteriaFields(Class businessObjectClass, Map fieldValues) Removes fields idenfied in the data dictionary as hidden from the lookup field values. | public void | setBusinessObjectDictionaryService(BusinessObjectDictionaryService businessObjectDictionaryService) | public void | setBusinessObjectMetaDataService(BusinessObjectMetaDataService businessObjectMetaDataService) Sets the businessObjectMetaDataService attribute value. | public void | setDataDictionaryService(DataDictionaryService ddService) | public static Field | setFieldQuickfinder(BusinessObject businessObject, String attributeName, Field field, List displayedFieldNames) | public static Field | setFieldQuickfinder(BusinessObject businessObject, String attributeName, Field field, List displayedFieldNames, SelectiveReferenceRefresher srr) | public static Field | setFieldQuickfinder(BusinessObject businessObject, String collectionName, boolean addLine, int index, String attributeName, Field field, List displayedFieldNames, SelectiveReferenceRefresher srr) Sets a fields quickfinder class and field conversions for an attribute. | public static Field | setFieldQuickfinder(BusinessObject businessObject, String collectionName, boolean addLine, int index, String attributeName, Field field, List displayedFieldNames) Sets a fields quickfinder class and field conversions for an attribute. | public void | setPersistenceStructureService(PersistenceStructureService persistenceStructureService) | public static Map | translateFieldConversions(String fieldConversionsString) This translates a , delimited list of pairs separated by a : into a Map of target --> lookup field conversions. | public static List<String> | translateReadOnlyFieldsToList(String readOnlyFieldsString) This makes a , delimited String list of fields separated by a , into a List of target --> lookup readOnlyFieldsList. |
LookupUtils | public LookupUtils()(Code) | | |
applySearchResultsLimit | public static void applySearchResultsLimit(Criteria criteria, KualiDBPlatform platform)(Code) | | |
convertReferencesToSelectCollectionToString | public static String convertReferencesToSelectCollectionToString(Collection<String> referencesToRefresh)(Code) | | |
convertSetOfObjectIdsToString | public static String convertSetOfObjectIdsToString(Set<String> objectIds)(Code) | | |
convertStringOfObjectIdsToSet | public static Set<String> convertStringOfObjectIdsToSet(String objectIdsString)(Code) | | |
findBestValueComparatorForColumn | public static Comparator findBestValueComparatorForColumn(List<ResultRow> resultTable, int column)(Code) | | Given a list of results from a lookup, determines the best comparator to use on the String values of each of these columns
This method exists because each cell (represented by the Column object) lists the comparator that should be used within it based on the property value class,
so we gotta go thru the whole list and determine the best comparator to use
Parameters: resultsTable - Parameters: column - |
forceUppercase | public static String forceUppercase(Class boClass, String fieldName, String fieldValue)(Code) | | This method uses the DataDictionary to determine whether to force uppercase the value, and if it should, then it does the
uppercase, and returns the upper-cased value.
Parameters: boClass - Parent BO class that the fieldName is a member of. Parameters: fieldName - Name of the field to be forced to uppercase. Parameters: fieldValue - Value of the field that may be uppercased. The correctly uppercased fieldValue if it should be uppercased, otherwise fieldValue is returned unchanged. |
forceUppercase | public static Map<String, String> forceUppercase(Class boClass, Map<String, String> fieldValues)(Code) | | This method uses the DataDictionary to determine whether to force uppercase the values, and if it should, then it does the
uppercase, and returns the upper-cased Map of fieldname/fieldValue pairs.
Parameters: boClass - Parent BO class that the fieldName is a member of. Parameters: fieldValues - A Map where the key is the fieldName and the value is the fieldValue. The same Map is returned, with the appropriate values uppercased (if any). |
generateCompositeSelectedObjectIds | public static Map<String, String> generateCompositeSelectedObjectIds(Set<String> previouslySelectedObjectIds, Set<String> displayedObjectIds, Set<String> selectedObjectIds)(Code) | | Given 3 sets of object IDs: the set of selected object IDs before rendering the current page,
the set of object IDs rendered on the page, and the set of object IDs selected on the page, computes
the total set of selected object IDs.
Instead of storing it in a set, returns it in a map with the selected object ID as both the key and value
Parameters: previouslySelectedObjectIds - Parameters: displayedObjectIds - Parameters: selectedObjectIds - |
getApplicationMaximumSearchResulsPerPageForMultipleValueLookups | public static Integer getApplicationMaximumSearchResulsPerPageForMultipleValueLookups()(Code) | | This method the maximum rows per page in a multiple value lookup
See Also: org.kuali.RiceConstants.SystemGroupParameterNames.MULTIPLE_VALUE_LOOKUP_RESULTS_PER_PAGE |
getApplicationSearchResultsLimit | public static Integer getApplicationSearchResultsLimit()(Code) | | |
getNestedBusinessObject | public static BusinessObject getNestedBusinessObject(BusinessObject bo, String attributeName)(Code) | | This method walks through the nested attribute and finds the last business object in the chain and returns it (excluding the
last parameter which is the actual attribute)
Parameters: attributeName - |
removeHiddenCriteriaFields | public static void removeHiddenCriteriaFields(Class businessObjectClass, Map fieldValues)(Code) | | Removes fields idenfied in the data dictionary as hidden from the lookup field values.
(This will remove Universal User ID and Person name from search requests when a user ID is entered.)
Parameters: fieldValues - |
setBusinessObjectMetaDataService | public void setBusinessObjectMetaDataService(BusinessObjectMetaDataService businessObjectMetaDataService)(Code) | | Sets the businessObjectMetaDataService attribute value.
Parameters: businessObjectMetaDataService - The businessObjectMetaDataService to set. |
setFieldQuickfinder | public static Field setFieldQuickfinder(BusinessObject businessObject, String collectionName, boolean addLine, int index, String attributeName, Field field, List displayedFieldNames)(Code) | | Sets a fields quickfinder class and field conversions for an attribute.
|
translateFieldConversions | public static Map translateFieldConversions(String fieldConversionsString)(Code) | | This translates a , delimited list of pairs separated by a : into a Map of target --> lookup field conversions.
Parameters: conversionFields - the Map representation of the fieldConversions String provided. |
translateReadOnlyFieldsToList | public static List<String> translateReadOnlyFieldsToList(String readOnlyFieldsString)(Code) | | This makes a , delimited String list of fields separated by a , into a List of target --> lookup readOnlyFieldsList.
Parameters: readOnlyFields - the List representation of the readOnlyFields String provided. |
|
|