org.kuali.student.common.ui.client.widgets.search
Class KSPicker

java.lang.Object
  extended by com.google.gwt.user.client.ui.UIObject
      extended by com.google.gwt.user.client.ui.Widget
          extended by com.google.gwt.user.client.ui.Composite
              extended by org.kuali.student.common.ui.client.widgets.search.KSPicker
All Implemented Interfaces:
com.google.gwt.event.logical.shared.HasValueChangeHandlers<String>, com.google.gwt.event.shared.HasHandlers, com.google.gwt.user.client.EventListener, HasCrossConstraints, HasDataValue, HasFocusLostCallbacks, TranslatableValueWidget, HasInputWidget
Direct Known Subclasses:
CluSetEditorWidget.Picker, CluSetsConfigurer.Picker, ClusetView.Picker

public class KSPicker
extends com.google.gwt.user.client.ui.Composite
implements HasFocusLostCallbacks, com.google.gwt.event.logical.shared.HasValueChangeHandlers<String>, HasDataValue, TranslatableValueWidget, HasInputWidget, HasCrossConstraints


Nested Class Summary
 class KSPicker.BasicWidget
           
private  class KSPicker.SelectionContainerWidget
           
 
Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObject
com.google.gwt.user.client.ui.UIObject.DebugIdImpl, com.google.gwt.user.client.ui.UIObject.DebugIdImplEnabled
 
Field Summary
private  Callback<List<SelectedResults>> advancedSearchCallback
           
private  com.google.gwt.user.client.ui.Anchor advSearchLink
           
private  AdvancedSearchWindow advSearchWindow
           
private  List<Callback<SelectedResults>> basicSelectionCallbacks
           
private  List<Callback<String>> basicSelectionTextChangeCallbacks
           
private  KSPicker.BasicWidget basicWidget
           
private  CachingSearchService cachingSearchService
           
private  WidgetConfigInfo config
           
private  HashSet<String> crossConstraints
           
private  boolean deferSearch
           
private  com.google.gwt.user.client.ui.FlowPanel layout
           
private  SearchPanel searchPanel
           
 
Fields inherited from class com.google.gwt.user.client.ui.UIObject
DEBUG_ID_PREFIX
 
Constructor Summary
KSPicker(LookupMetadata inLookupMetadata, List<LookupMetadata> additionalLookupMetadata)
           
KSPicker(WidgetConfigInfo config)
           
 
Method Summary
 void addBasicSelectionCompletedCallback(Callback<SelectedResults> callback)
           
 void addBasicSelectionTextChangeCallback(Callback<String> callback)
           
 void addFocusLostCallback(Callback<Boolean> callback)
           
 void addSelectionChangeHandler(SelectionChangeHandler handler)
           
 void addValueChangeCallback(Callback<Data.Value> callback)
           
 com.google.gwt.event.shared.HandlerRegistration addValueChangeHandler(com.google.gwt.event.logical.shared.ValueChangeHandler<String> handler)
           
 void addValuesChangeHandler(com.google.gwt.event.logical.shared.ValueChangeHandler<List<String>> handler)
           
 void clear()
           
 HashSet<String> getCrossConstraints()
           
 String getDisplayValue()
           
 com.google.gwt.user.client.ui.Widget getInputWidget()
           
private  List<LookupMetadata> getLookupMetadataBasedOnWidget(List<LookupMetadata> additionalLookupMetadata, LookupMetadata.Widget widgetType)
           
private static String getMessage(String messageId)
           
 SearchPanel getSearchPanel()
           
 AdvancedSearchWindow getSearchWindow()
           
 Data.Value getValue()
           
private  void init(LookupMetadata inLookupMetadata, List<LookupMetadata> additionalLookupMetadata)
           
private  SearchRequest initializeSearchRequest(LookupMetadata lookup)
           
private  void populateListWidget(SearchRequest sr)
           
 void reprocessWithUpdatedConstraints()
           
 void setAdvancedSearchCallback(Callback<List<SelectedResults>> advancedSearchCallback)
           
private  void setupAdvancedSearch(List<LookupMetadata> additionalLookupMetadata)
           
private  void setupBasicSearch(LookupMetadata inLookupMetadata)
           
private  void setupDefaultWidget(LookupMetadata inLookupMetadata)
           
private  void setupListWidget(LookupMetadata inLookupMetadata)
           
private  void setupSuggestBox(LookupMetadata inLookupMetadata)
           
 void setValue(Data.Value value)
           
 void setValue(Data.Value value, boolean fireEvents)
           
 void setValue(Map<String,String> translations)
           
 void setValue(String value)
           
 void setValue(String id, String translation)
           
 
Methods inherited from class com.google.gwt.user.client.ui.Composite
getWidget, initWidget, isAttached, onAttach, onBrowserEvent, onDetach, setWidget
 
Methods inherited from class com.google.gwt.user.client.ui.Widget
addDomHandler, addHandler, delegateEvent, doAttachChildren, doDetachChildren, fireEvent, getHandlerCount, getLayoutData, getParent, isOrWasAttached, onLoad, onUnload, removeFromParent, setLayoutData, sinkEvents
 
Methods inherited from class com.google.gwt.user.client.ui.UIObject
addStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, setElement, setElement, setHeight, setPixelSize, setSize, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, toString, unsinkEvents
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.google.gwt.event.shared.HasHandlers
fireEvent
 

Field Detail

layout

private com.google.gwt.user.client.ui.FlowPanel layout

basicWidget

private KSPicker.BasicWidget basicWidget

advSearchLink

private com.google.gwt.user.client.ui.Anchor advSearchLink

advSearchWindow

private AdvancedSearchWindow advSearchWindow

searchPanel

private SearchPanel searchPanel

config

private WidgetConfigInfo config

advancedSearchCallback

private Callback<List<SelectedResults>> advancedSearchCallback

basicSelectionCallbacks

private List<Callback<SelectedResults>> basicSelectionCallbacks

basicSelectionTextChangeCallbacks

private List<Callback<String>> basicSelectionTextChangeCallbacks

cachingSearchService

private CachingSearchService cachingSearchService

crossConstraints

private HashSet<String> crossConstraints

deferSearch

private boolean deferSearch
Constructor Detail

KSPicker

public KSPicker(WidgetConfigInfo config)

KSPicker

public KSPicker(LookupMetadata inLookupMetadata,
                List<LookupMetadata> additionalLookupMetadata)
Method Detail

getSearchPanel

public SearchPanel getSearchPanel()

getInputWidget

public com.google.gwt.user.client.ui.Widget getInputWidget()
Specified by:
getInputWidget in interface HasInputWidget

init

private void init(LookupMetadata inLookupMetadata,
                  List<LookupMetadata> additionalLookupMetadata)

getMessage

private static String getMessage(String messageId)

setupBasicSearch

private void setupBasicSearch(LookupMetadata inLookupMetadata)

setupDefaultWidget

private void setupDefaultWidget(LookupMetadata inLookupMetadata)

setupSuggestBox

private void setupSuggestBox(LookupMetadata inLookupMetadata)

setupListWidget

private void setupListWidget(LookupMetadata inLookupMetadata)

setupAdvancedSearch

private void setupAdvancedSearch(List<LookupMetadata> additionalLookupMetadata)

populateListWidget

private void populateListWidget(SearchRequest sr)

getLookupMetadataBasedOnWidget

private List<LookupMetadata> getLookupMetadataBasedOnWidget(List<LookupMetadata> additionalLookupMetadata,
                                                            LookupMetadata.Widget widgetType)

initializeSearchRequest

private SearchRequest initializeSearchRequest(LookupMetadata lookup)

getSearchWindow

public AdvancedSearchWindow getSearchWindow()

addBasicSelectionCompletedCallback

public void addBasicSelectionCompletedCallback(Callback<SelectedResults> callback)

addBasicSelectionTextChangeCallback

public void addBasicSelectionTextChangeCallback(Callback<String> callback)

addValueChangeCallback

public void addValueChangeCallback(Callback<Data.Value> callback)
Specified by:
addValueChangeCallback in interface HasDataValue

setValue

public void setValue(Data.Value value)
Specified by:
setValue in interface HasDataValue

setValue

public void setValue(String value)

setValue

public void setValue(Data.Value value,
                     boolean fireEvents)

clear

public void clear()

setValue

public void setValue(String id,
                     String translation)
Specified by:
setValue in interface TranslatableValueWidget

getValue

public Data.Value getValue()
Specified by:
getValue in interface HasDataValue

getDisplayValue

public String getDisplayValue()

addValueChangeHandler

public com.google.gwt.event.shared.HandlerRegistration addValueChangeHandler(com.google.gwt.event.logical.shared.ValueChangeHandler<String> handler)
Specified by:
addValueChangeHandler in interface com.google.gwt.event.logical.shared.HasValueChangeHandlers<String>

addValuesChangeHandler

public void addValuesChangeHandler(com.google.gwt.event.logical.shared.ValueChangeHandler<List<String>> handler)

addSelectionChangeHandler

public void addSelectionChangeHandler(SelectionChangeHandler handler)

addFocusLostCallback

public void addFocusLostCallback(Callback<Boolean> callback)
Specified by:
addFocusLostCallback in interface HasFocusLostCallbacks

setAdvancedSearchCallback

public void setAdvancedSearchCallback(Callback<List<SelectedResults>> advancedSearchCallback)

setValue

public void setValue(Map<String,String> translations)
Specified by:
setValue in interface TranslatableValueWidget

getCrossConstraints

public HashSet<String> getCrossConstraints()
Specified by:
getCrossConstraints in interface HasCrossConstraints

reprocessWithUpdatedConstraints

public void reprocessWithUpdatedConstraints()
Specified by:
reprocessWithUpdatedConstraints in interface HasCrossConstraints


Copyright © 2007-2011 The Kuali Foundation. All Rights Reserved.