org.kuali.rice.krad.uif.service.impl
Class ViewDictionaryServiceImpl

java.lang.Object
  extended by org.kuali.rice.krad.uif.service.impl.ViewDictionaryServiceImpl
All Implemented Interfaces:
ViewDictionaryService

public class ViewDictionaryServiceImpl
extends Object
implements ViewDictionaryService

Implementation of ViewDictionaryService

Pulls view entries from the data dictionary to implement the various query methods

Author:
Kuali Rice Team (rice.collab@kuali.org)

Constructor Summary
ViewDictionaryServiceImpl()
           
 
Method Summary
protected  DataDictionary getDataDictionary()
           
protected  DataDictionaryService getDataDictionaryService()
           
 Inquirable getInquirable(Class<?> dataObjectClass, String viewName)
          Queries the dictionary to find the InquiryView configured for the data object class and returns the configured Inquirable for the view.
 Integer getResultSetLimitForLookup(Class<?> dataObjectClass, LookupForm lookupForm)
          Attempts to find an associated LookupView for the given data object class and if found returns the configured result set limit, if multiple lookup views are found the default is used unless the specific view can be found by view ID
 ViewSessionPolicy getViewSessionPolicy(String viewId)
          Retrieves the ViewSessionPolicy instance associated with the given view id
 boolean isInquirable(Class<?> dataObjectClass)
          Indicates whether the given data object class has an associated InquiryView configured and thus can have inquiry links built
 boolean isLookupable(Class<?> dataObjectClass)
          Indicates whether the given data object class has an associated LookupView configured and thus can have quickfinders associated with the class
 boolean isMaintainable(Class<?> dataObjectClass)
          Indicates whether the given data object class has an associated MaintenanceDocumentView configured
 boolean isSessionStorageEnabled(String viewId)
          Indicates whether session storage is enabled for the view associated with the given id
 void setDataDictionaryService(DataDictionaryService dataDictionaryService)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ViewDictionaryServiceImpl

public ViewDictionaryServiceImpl()
Method Detail

getInquirable

public Inquirable getInquirable(Class<?> dataObjectClass,
                                String viewName)
Description copied from interface: ViewDictionaryService
Queries the dictionary to find the InquiryView configured for the data object class and returns the configured Inquirable for the view. If more than one inquiry view exists for the data object class, the one that matches the given viewName, or the default if viewName is blank is used

Specified by:
getInquirable in interface ViewDictionaryService
Parameters:
dataObjectClass - - class for the inquiry data object
viewName - - name of the inquiry view, can be blank in which case the 'default' name will be used
Returns:
Inquirable configured inquirable for the view, or null if view is not found
See Also:
ViewDictionaryService.getInquirable(java.lang.Class, java.lang.String)

isInquirable

public boolean isInquirable(Class<?> dataObjectClass)
Description copied from interface: ViewDictionaryService
Indicates whether the given data object class has an associated InquiryView configured and thus can have inquiry links built

Specified by:
isInquirable in interface ViewDictionaryService
Parameters:
dataObjectClass - - object class to get inquiry view for
Returns:
boolean true if the class has an inquiry view, false if no inquiry view exists for the class
See Also:
ViewDictionaryService.isInquirable(java.lang.Class)

isLookupable

public boolean isLookupable(Class<?> dataObjectClass)
Description copied from interface: ViewDictionaryService
Indicates whether the given data object class has an associated LookupView configured and thus can have quickfinders associated with the class

Specified by:
isLookupable in interface ViewDictionaryService
Parameters:
dataObjectClass - - object class to get lookup view for
Returns:
boolean true if the class has an lookup view, false if no lookup view exists for the class
See Also:
ViewDictionaryService.isLookupable(java.lang.Class)

isMaintainable

public boolean isMaintainable(Class<?> dataObjectClass)
Description copied from interface: ViewDictionaryService
Indicates whether the given data object class has an associated MaintenanceDocumentView configured

Specified by:
isMaintainable in interface ViewDictionaryService
Parameters:
dataObjectClass - - object class to get maintenance view for
Returns:
boolean true if the class has an maintenance view, false if no maintenance view exists for the class
See Also:
ViewDictionaryService.isMaintainable(java.lang.Class)

getResultSetLimitForLookup

public Integer getResultSetLimitForLookup(Class<?> dataObjectClass,
                                          LookupForm lookupForm)
Description copied from interface: ViewDictionaryService
Attempts to find an associated LookupView for the given data object class and if found returns the configured result set limit, if multiple lookup views are found the default is used unless the specific view can be found by view ID

Specified by:
getResultSetLimitForLookup in interface ViewDictionaryService
Parameters:
dataObjectClass - - object class to get lookup view for
lookupForm - - the LookupForm
Returns:
Integer configured result set limit for lookup, or null if not found (note property could also be null on the view itself)
See Also:
If the form is null, only the dataObjectClass will be used to find the LookupView and corresponding results set limit. Since the viewID is not known, the default view will be used.

getViewSessionPolicy

public ViewSessionPolicy getViewSessionPolicy(String viewId)
Description copied from interface: ViewDictionaryService
Retrieves the ViewSessionPolicy instance associated with the given view id

Specified by:
getViewSessionPolicy in interface ViewDictionaryService
Parameters:
viewId - id for the view whose session policy should be retrieved
Returns:
view session policy instance for view or null if view not found for the given id
See Also:
ViewDictionaryService.getViewSessionPolicy(java.lang.String)

isSessionStorageEnabled

public boolean isSessionStorageEnabled(String viewId)
Description copied from interface: ViewDictionaryService
Indicates whether session storage is enabled for the view associated with the given id

Specified by:
isSessionStorageEnabled in interface ViewDictionaryService
Parameters:
viewId - id for the view to check
Returns:
true if session storage is enabled, false if not enabled or the view was not found
See Also:
ViewDictionaryService.isSessionStorageEnabled(java.lang.String)

getDataDictionary

protected DataDictionary getDataDictionary()

getDataDictionaryService

protected DataDictionaryService getDataDictionaryService()

setDataDictionaryService

public void setDataDictionaryService(DataDictionaryService dataDictionaryService)


Copyright © 2005-2013 The Kuali Foundation. All Rights Reserved.