com.smartgwt.client.widgets.form
Class FilterBuilder

java.lang.Object
  extended by com.google.gwt.user.client.ui.UIObject
      extended by com.google.gwt.user.client.ui.Widget
          extended by com.smartgwt.client.widgets.BaseWidget
              extended by com.smartgwt.client.widgets.Canvas
                  extended by com.smartgwt.client.widgets.layout.Layout
                      extended by com.smartgwt.client.widgets.form.FilterBuilder
All Implemented Interfaces:
HasHandlers, EventListener, HasClickHandlers, HasDoubleClickHandlers, HasDragMoveHandlers, HasDragRepositionMoveHandlers, HasDragRepositionStartHandlers, HasDragRepositionStopHandlers, HasDragResizeMoveHandlers, HasDragResizeStartHandlers, HasDragResizeStopHandlers, HasDragStartHandlers, HasDragStopHandlers, HasDropHandlers, HasDropMoveHandlers, HasDropOutHandlers, HasDropOverHandlers, HasFocusChangedHandlers, HasHoverHandlers, HasHoverHiddenHandlers, HasKeyDownHandlers, HasKeyPressHandlers, HasMouseDownHandlers, HasMouseMoveHandlers, HasMouseOutHandlers, HasMouseOverHandlers, HasMouseStillDownHandlers, HasMouseUpHandlers, HasMouseWheelHandlers, HasResizedHandlers, HasRightMouseDownHandlers, HasScrolledHandlers, HasShowContextMenuHandlers, HasFilterChangedHandlers, HasSearchHandlers

public class FilterBuilder
extends Layout
implements HasFilterChangedHandlers, HasSearchHandlers

A form that allows the user to input advanced search criteria, including operators on field values such as "less than", and sub-clauses using "AND" and "OR" operators.

A FilterBuilder produces an ${isc.DocUtils.linkForRef('object:AdvancedCriteria')} object, which the DataSource subsystem can use to filter datasets, including the ability to perform such filtering within the browser for datasets that are completely loaded.


Nested Class Summary
 
Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObject
UIObject.DebugIdImpl, UIObject.DebugIdImplEnabled
 
Field Summary
 
Fields inherited from class com.smartgwt.client.widgets.BaseWidget
config, configOnly, id, isElementSet, scClassName
 
Fields inherited from class com.google.gwt.user.client.ui.UIObject
DEBUG_ID_PREFIX
 
Constructor Summary
FilterBuilder()
           
FilterBuilder(JavaScriptObject jsObj)
           
 
Method Summary
 HandlerRegistration addFilterChangedHandler(FilterChangedHandler handler)
          Add a filterChanged handler.
 HandlerRegistration addSearchHandler(SearchHandler handler)
          Add a search handler.
 void clearCriteria()
          Clear all current criteria.
protected  JavaScriptObject create()
           
 String getAddButtonPrompt()
          The hover prompt text for the add button.
 Boolean getAllowEmpty()
          If set to false, the last clause cannot be removed.
 AdvancedCriteria getCriteria()
          Initial criteria.
 DataSource getDataSource()
          The DataSource that this component should bind to for default fields and for performing DSRequest.
static FilterBuilder getOrCreateRef(JavaScriptObject jsObj)
           
 String getRangeSeparator()
          For operators that check that a value is within a range, text to show between the start and end input fields for specifying the limits of the range.
 String getRemoveButtonPrompt()
          The hover prompt text for the remove button.
 Boolean getSaveOnEnter()
          If true, when the user hits the Enter key while focussed in a text-item in this FilterBuilder, we automatically invoke the user-supplied addSearchHandler(com.smartgwt.client.widgets.form.events.SearchHandler) method.
 Boolean getShowAddButton()
          If set, a button will be shown underneath all current clauses allowing a new clause to be added.
 Boolean getShowFieldTitles()
          If true (the default), show field titles in the drop-down box used to select a field for querying.
 Boolean getShowRemoveButton()
          If set, a button will be shown for each clause allowing it to be removed.
 Boolean getShowSubClauseButton()
          Whether to show a button that allows the user to add subclauses.
 String getSubClauseButtonPrompt()
          The hover prompt text for the subClauseButton.
 String getSubClauseButtonTitle()
          The hover title text of the subClauseButton
 LogicalOperator getTopOperator()
          Default logical operator for all top-level clauses in the FilterBuilder.
 Boolean getValidateOnChange()
          If true (the default), validates each entered value when it changes, to make sure it is a a valid value of its type (valid string, number, and so on).
 void setAddButtonPrompt(String addButtonPrompt)
          The hover prompt text for the add button.
 void setAllowEmpty(Boolean allowEmpty)
          If set to false, the last clause cannot be removed.
 void setCriteria(AdvancedCriteria criteria)
          Initial criteria.
 void setDataSource(DataSource dataSource)
          DataSource this filter should use for field definitions and available ${isc.DocUtils.linkForRef('object:Operator')}s.
 void setRangeSeparator(String rangeSeparator)
          For operators that check that a value is within a range, text to show between the start and end input fields for specifying the limits of the range.
 void setRemoveButtonPrompt(String removeButtonPrompt)
          The hover prompt text for the remove button.
 void setSaveOnEnter(Boolean saveOnEnter)
          If true, when the user hits the Enter key while focussed in a text-item in this FilterBuilder, we automatically invoke the user-supplied addSearchHandler(com.smartgwt.client.widgets.form.events.SearchHandler) method.
 void setShowAddButton(Boolean showAddButton)
          If set, a button will be shown underneath all current clauses allowing a new clause to be added.
 void setShowFieldTitles(boolean showFieldTitles)
          If true (the default), show field titles in the drop-down box used to select a field for querying.
 void setShowFieldTitles(Boolean showFieldTitles)
          If true (the default), show field titles in the drop-down box used to select a field for querying.
 void setShowRemoveButton(Boolean showRemoveButton)
          If set, a button will be shown for each clause allowing it to be removed.
 void setShowSubClauseButton(Boolean showSubClauseButton)
          Whether to show a button that allows the user to add subclauses.
 void setSubClauseButtonPrompt(String subClauseButtonPrompt)
          The hover prompt text for the subClauseButton.
 void setSubClauseButtonTitle(String subClauseButtonTitle)
          The hover title text of the subClauseButton
 void setTopOperator(LogicalOperator topOperator)
          Default logical operator for all top-level clauses in the FilterBuilder.
 void setTopOperatorAppearance(TopOperatorAppearance topOperatorAppearance)
          How to display and edit the topOperator for this FilterBuilder.
 void setValidateOnChange(Boolean validateOnChange)
          If true (the default), validates each entered value when it changes, to make sure it is a a valid value of its type (valid string, number, and so on).
 
Methods inherited from class com.smartgwt.client.widgets.layout.Layout
addMember, addMember, addMember, addMember, addMemberPostCreate, addMemberPostCreate, addMemberPreCreate, addMemberPreCreate, getAnimateMembers, getAnimateMemberTime, getCanDropComponents, getDefaultResizeBars, getDropComponent, getDropLineThickness, getDropPosition, getEnforcePolicy, getHPolicy, getLayoutBottomMargin, getLayoutLeftMargin, getLayoutMargin, getLayoutRightMargin, getLayoutTopMargin, getLeaveScrollbarGap, getManagePercentBreadth, getMember, getMember, getMemberDefaultBreadth, getMemberNumber, getMemberNumber, getMemberOffset, getMemberOverlap, getMembers, getMembersMargin, getMinMemberSize, getOverflow, getPaddingAsLayoutMargin, getResizeBarClass, getResizeBarSize, getReverseOrder, getShowDragPlaceHolder, getStackZIndex, getVertical, getVPolicy, hasMember, hideDropLine, hideMember, hideMember, membersChanged, onInit, reflow, reflow, reflowNow, removeMember, removeMembers, reorderMember, reorderMembers, setAlign, setAlign, setAnimateMembers, setAnimateMemberTime, setCanDropComponents, setDefaultLayoutAlign, setDefaultLayoutAlign, setDefaultResizeBars, setDropLineProperties, setDropLineThickness, setEnforcePolicy, setHPolicy, setLayoutBottomMargin, setLayoutLeftMargin, setLayoutMargin, setLayoutRightMargin, setLayoutTopMargin, setLeaveScrollbarGap, setManagePercentBreadth, setMemberOverlap, setMembers, setMembersMargin, setMinMemberSize, setOverflow, setPaddingAsLayoutMargin, setPlaceHolderDefaults, setPlaceHolderProperties, setResizeBarClass, setResizeBarSize, setReverseOrder, setShowDragPlaceHolder, setStackZIndex, setVertical, setVisibleMember, setVPolicy, showMember, showMember
 
Methods inherited from class com.smartgwt.client.widgets.Canvas
addChild, addChild, addChild, addClickHandler, addDoubleClickHandler, addDragMoveHandler, addDragRepositionMoveHandler, addDragRepositionStartHandler, addDragRepositionStopHandler, addDragResizeMoveHandler, addDragResizeStartHandler, addDragResizeStopHandler, addDragStartHandler, addDragStopHandler, addDropHandler, addDropMoveHandler, addDropOutHandler, addDropOverHandler, addFocusChangedHandler, addHoverHandler, addHoverHiddenHandler, addKeyDownHandler, addKeyPressHandler, addMouseDownHandler, addMouseMoveHandler, addMouseOutHandler, addMouseOverHandler, addMouseStillDownHandler, addMouseUpHandler, addMouseWheelHandler, addPeer, addPeer, addResizedHandler, addRightMouseDownHandler, addScrolledHandler, addShowContextMenuHandler, addStyleName, adjustForContent, animateFade, animateFade, animateFade, animateHide, animateHide, animateHide, animateMove, animateMove, animateMove, animateMove, animateRect, animateRect, animateRect, animateResize, animateResize, animateResize, animateScroll, animateScroll, animateScroll, animateShow, animateShow, animateShow, blur, bringToFront, clear, clickMaskUp, clickMaskUp, contains, contains, containsEvent, containsFocus, containsPoint, containsPoint, convertToCanvasArray, disable, enable, focus, getAbsoluteLeft, getAbsoluteTop, getAccessKey, getAnimateAcceleration, getAnimateFadeTime, getAnimateHideAcceleration, getAnimateHideTime, getAnimateMoveAcceleration, getAnimateMoveTime, getAnimateRectAcceleration, getAnimateRectTime, getAnimateResizeAcceleration, getAnimateResizeTime, getAnimateScrollAcceleration, getAnimateScrollTime, getAnimateShowAcceleration, getAnimateShowTime, getAnimateTime, getAppImgDir, getAutoShowParent, getBackgroundImage, getBackgroundPosition, getBackgroundRepeat, getBorder, getBottom, getById, getCanAcceptDrop, getCanDrag, getCanDragReposition, getCanDragResize, getCanDragScroll, getCanDrop, getCanDropBefore, getCanFocus, getCanHover, getCanSelectText, getChildren, getChildrenSnapResizeToGrid, getChildrenSnapToGrid, getContents, getContextMenu, getCursor, getDataPath, getDefaultHeight, getDefaultWidth, getDestroyed, getDestroying, getDisabled, getDisabledCursor, getDoubleClickDelay, getDragAppearance, getDragIntersectStyle, getDragOpacity, getDragRepositionCursor, getDragScrollDelay, getDragStartDistance, getDragTarget, getDragType, getDynamicContents, getEdgeBackgroundColor, getEdgeCenterBackgroundColor, getEdgeImage, getEdgeOffset, getEdgeOpacity, getEdgeShowCenter, getEdgeSize, getExtraSpace, getFullDataPath, getGroupTitle, getHeight, getHeightAsString, getHoverAlign, getHoverDelay, getHoverHeight, getHoverHTML, getHoverMoveWithMouse, getHoverOpacity, getHoverStyle, getHoverVAlign, getHoverWidth, getHoverWrap, getHSnapOrigin, getHSnapOrigin, getHSnapPosition, getHSnapPosition, getHtmlPosition, getImgURL, getImgURL, getInnerContentHeight, getInnerContentWidth, getInnerHeight, getInnerWidth, getIsGroup, getLeft, getLeftAsString, getMargin, getMatchElement, getMaxHeight, getMaxWidth, getMinHeight, getMinWidth, getMouseStillDownDelay, getMouseStillDownInitialDelay, getNextZIndex, getNoDoubleClicks, getOffsetHeight, getOffsetWidth, getOffsetX, getOffsetY, getOpacity, getPadding, getPageBottom, getPageLeft, getPageRect, getPageRight, getPageTop, getParentElement, getPercentBox, getPosition, getPrefix, getPrompt, getRect, getRedrawOnResize, getResizeBarTarget, getRight, getScrollbarSize, getScrollBottom, getScrollHeight, getScrollLeft, getScrollRight, getScrollTop, getScrollWidth, getShadowDepth, getShadowImage, getShadowOffset, getShadowSoftness, getShowCustomScrollbars, getShowDragShadow, getShowEdges, getShowHover, getShowResizeBar, getShowShadow, getSkinImgDir, getSnapAxis, getSnapEdge, getSnapHDirection, getSnapHGap, getSnapOffsetLeft, getSnapOffsetTop, getSnapOnDrop, getSnapResizeToGrid, getSnapTo, getSnapToGrid, getSnapVDirection, getSnapVGap, getStyleName, getTabIndex, getTitle, getTooltip, getTop, getTopAsString, getValuesManager, getViewportHeight, getViewportWidth, getVisibility, getVisibleHeight, getVisibleWidth, getVSnapOrigin, getVSnapOrigin, getVSnapPosition, getVSnapPosition, getWidth, getWidthAsString, getZIndex, handleHover, hide, hideClickMask, hideClickMask, hideContextMenu, imgHTML, imgHTML, imgHTML, intersects, isDirty, isDisabled, isDrawn, isVisible, keyUp, layoutChildren, linkHTML, linkHTML, markForDestroy, markForRedraw, markForRedraw, moveAbove, moveBelow, moveBy, moveTo, parentResized, redraw, redraw, removeChild, removeChild, resizeBy, resizeTo, resizeTo, scrollBy, scrollByPercent, scrollTo, scrollTo, scrollToBottom, scrollToLeft, scrollToPercent, scrollToRight, scrollToTop, sendToBack, setAccessKey, setAnimateAcceleration, setAnimateFadeTime, setAnimateHideAcceleration, setAnimateHideTime, setAnimateMoveAcceleration, setAnimateMoveTime, setAnimateRectAcceleration, setAnimateRectTime, setAnimateResizeAcceleration, setAnimateResizeTime, setAnimateScrollAcceleration, setAnimateScrollTime, setAnimateShowAcceleration, setAnimateShowTime, setAnimateTime, setAppImgDir, setAutoHeight, setAutoShowParent, setAutoWidth, setBackgroundColor, setBackgroundImage, setBackgroundPosition, setBackgroundRepeat, setBorder, setBottom, setCanAcceptDrop, setCanDrag, setCanDragReposition, setCanDragResize, setCanDragScroll, setCanDrop, setCanDropBefore, setCanFocus, setCanHover, setCanSelectText, setChildren, setChildrenSnapResizeToGrid, setChildrenSnapToGrid, setContents, setContextMenu, setCursor, setDataPath, setDefaultHeight, setDefaultWidth, setDisabled, setDisabledCursor, setDoubleClickDelay, setDragAppearance, setDragIntersectStyle, setDragOpacity, setDragRepositionCursor, setDragScrollDelay, setDragStartDistance, setDragTarget, setDragType, setDropTypes, setDynamicContents, setEdgeBackgroundColor, setEdgeCenterBackgroundColor, setEdgeImage, setEdgeMarginSize, setEdgeOffset, setEdgeOpacity, setEdgeShowCenter, setEdgeSize, setExtraSpace, setGroupTitle, setHeight, setHeight, setHeight100, setHoverAlign, setHoverDelay, setHoverHeight, setHoverMoveWithMouse, setHoverOpacity, setHoverStyle, setHoverVAlign, setHoverWidth, setHoverWrap, setHtmlPosition, setImage, setImage, setIsGroup, setKeepInParentRect, setKeepInParentRect, setLayoutAlign, setLayoutAlign, setLeft, setLeft, setMargin, setMatchElement, setMaxHeight, setMaxWidth, setMinHeight, setMinWidth, setMouseStillDownDelay, setMouseStillDownInitialDelay, setNoDoubleClicks, setOpacity, setPadding, setPageLeft, setPageTop, setParentElement, setPercentBox, setPosition, setPrefix, setPrompt, setRect, setRect, setRedrawOnResize, setResizeBarTarget, setResizeFrom, setRight, setScrollbarSize, setShadowDepth, setShadowImage, setShadowOffset, setShadowSoftness, setShowCustomScrollbars, setShowDragShadow, setShowEdges, setShowHover, setShowResizeBar, setShowShadow, setSkinImgDir, setSmoothFade, setSnapAxis, setSnapEdge, setSnapHDirection, setSnapHGap, setSnapOffsetLeft, setSnapOffsetTop, setSnapOnDrop, setSnapResizeToGrid, setSnapTo, setSnapToGrid, setSnapVDirection, setSnapVGap, setStyleName, setTabIndex, setTitle, setTooltip, setTop, setTop, setValuesManager, setVisibility, setVisible, setWidth, setWidth, setWidth100, setZIndex, shouldDragScroll, show, showClickMask, showNextTo, showNextTo, showPrintPreview, updateHover, updateHover, updateShadow, visibleAtPoint, visibleAtPoint, willAcceptDrop
 
Methods inherited from class com.smartgwt.client.widgets.BaseWidget
addDrawHandler, destroy, doAddHandler, doInit, doOnRender, draw, equals, error, errorIfNotCreated, fireEvent, getAttribute, getAttributeAsBoolean, getAttributeAsDate, getAttributeAsDouble, getAttributeAsElement, getAttributeAsFloat, getAttributeAsInt, getAttributeAsJavaScriptObject, getAttributeAsMap, getAttributeAsString, getAttributeAsStringArray, getConfig, getDOM, getElement, getElement, getHandlerCount, getID, getInnerHTML, getJsObj, getOrCreateJsObj, getRef, hashCode, isConfigOnly, isCreated, onDestroy, onDraw, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setConfig, setConfigOnly, setDragTracker, setElement, setHtmlElement, setID, setNullProperty, setPosition, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, toString
 
Methods inherited from class com.google.gwt.user.client.ui.Widget
addDomHandler, addHandler, delegateEvent, doAttachChildren, doDetachChildren, getLayoutData, getParent, isAttached, isOrWasAttached, onAttach, onBrowserEvent, onDetach, onLoad, onUnload, removeFromParent, setLayoutData, sinkEvents
 
Methods inherited from class com.google.gwt.user.client.ui.UIObject
addStyleDependentName, ensureDebugId, ensureDebugId, ensureDebugId, getStyleElement, getStyleName, getStylePrimaryName, getStylePrimaryName, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, setElement, setPixelSize, setSize, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setVisible, unsinkEvents
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.google.gwt.event.shared.HasHandlers
fireEvent
 

Constructor Detail

FilterBuilder

public FilterBuilder()

FilterBuilder

public FilterBuilder(JavaScriptObject jsObj)
Method Detail

getOrCreateRef

public static FilterBuilder getOrCreateRef(JavaScriptObject jsObj)

create

protected JavaScriptObject create()
Overrides:
create in class Layout

setSaveOnEnter

public void setSaveOnEnter(Boolean saveOnEnter)
                    throws IllegalStateException
If true, when the user hits the Enter key while focussed in a text-item in this FilterBuilder, we automatically invoke the user-supplied addSearchHandler(com.smartgwt.client.widgets.form.events.SearchHandler) method.

Parameters:
saveOnEnter - saveOnEnter Default value is null
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getSaveOnEnter

public Boolean getSaveOnEnter()
If true, when the user hits the Enter key while focussed in a text-item in this FilterBuilder, we automatically invoke the user-supplied addSearchHandler(com.smartgwt.client.widgets.form.events.SearchHandler) method.

Returns:
Boolean

setShowFieldTitles

public void setShowFieldTitles(Boolean showFieldTitles)
                        throws IllegalStateException
If true (the default), show field titles in the drop-down box used to select a field for querying. If false, show actual field names instead.

Parameters:
showFieldTitles - showFieldTitles Default value is true
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getShowFieldTitles

public Boolean getShowFieldTitles()
If true (the default), show field titles in the drop-down box used to select a field for querying. If false, show actual field names instead.

Returns:
Boolean

setValidateOnChange

public void setValidateOnChange(Boolean validateOnChange)
                         throws IllegalStateException
If true (the default), validates each entered value when it changes, to make sure it is a a valid value of its type (valid string, number, and so on). No other validation is carried out. If you switch this property off, it is still possible to validate the FilterBuilder by calling ${isc.DocUtils.linkForRef('filterBuilder.validate')} from your own code.

Parameters:
validateOnChange - validateOnChange Default value is true
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getValidateOnChange

public Boolean getValidateOnChange()
If true (the default), validates each entered value when it changes, to make sure it is a a valid value of its type (valid string, number, and so on). No other validation is carried out. If you switch this property off, it is still possible to validate the FilterBuilder by calling ${isc.DocUtils.linkForRef('filterBuilder.validate')} from your own code.

Returns:
Boolean

setShowRemoveButton

public void setShowRemoveButton(Boolean showRemoveButton)
                         throws IllegalStateException
If set, a button will be shown for each clause allowing it to be removed.

Parameters:
showRemoveButton - showRemoveButton Default value is true
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getShowRemoveButton

public Boolean getShowRemoveButton()
If set, a button will be shown for each clause allowing it to be removed.

Returns:
Boolean

setRemoveButtonPrompt

public void setRemoveButtonPrompt(String removeButtonPrompt)
                           throws IllegalStateException
The hover prompt text for the remove button.

Parameters:
removeButtonPrompt - removeButtonPrompt Default value is "Remove"
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getRemoveButtonPrompt

public String getRemoveButtonPrompt()
The hover prompt text for the remove button.

Returns:
String

setShowAddButton

public void setShowAddButton(Boolean showAddButton)
                      throws IllegalStateException
If set, a button will be shown underneath all current clauses allowing a new clause to be added.

Parameters:
showAddButton - showAddButton Default value is true
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getShowAddButton

public Boolean getShowAddButton()
If set, a button will be shown underneath all current clauses allowing a new clause to be added.

Returns:
Boolean

setAddButtonPrompt

public void setAddButtonPrompt(String addButtonPrompt)
                        throws IllegalStateException
The hover prompt text for the add button.

Parameters:
addButtonPrompt - addButtonPrompt Default value is "Add"
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getAddButtonPrompt

public String getAddButtonPrompt()
The hover prompt text for the add button.

Returns:
String

setAllowEmpty

public void setAllowEmpty(Boolean allowEmpty)
                   throws IllegalStateException
If set to false, the last clause cannot be removed.

Parameters:
allowEmpty - allowEmpty Default value is false
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getAllowEmpty

public Boolean getAllowEmpty()
If set to false, the last clause cannot be removed.

Returns:
Boolean

setTopOperator

public void setTopOperator(LogicalOperator topOperator)
Default logical operator for all top-level clauses in the FilterBuilder.

May be able to be changed by the user via the UI, according to com.smartgwt.client..TopOperatorAppearance. Programmatically change the topOperator for this FilterBuilder.

Parameters:
topOperator - new top-level operator. Default value is "and"

getTopOperator

public LogicalOperator getTopOperator()
Default logical operator for all top-level clauses in the FilterBuilder.

May be able to be changed by the user via the UI, according to com.smartgwt.client..TopOperatorAppearance.

Returns:
LogicalOperator

setRangeSeparator

public void setRangeSeparator(String rangeSeparator)
                       throws IllegalStateException
For operators that check that a value is within a range, text to show between the start and end input fields for specifying the limits of the range.

Parameters:
rangeSeparator - rangeSeparator Default value is "and"
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getRangeSeparator

public String getRangeSeparator()
For operators that check that a value is within a range, text to show between the start and end input fields for specifying the limits of the range.

Returns:
String

setShowSubClauseButton

public void setShowSubClauseButton(Boolean showSubClauseButton)
                            throws IllegalStateException
Whether to show a button that allows the user to add subclauses. Defaults to false if the com.smartgwt.client..TopOperatorAppearance is "radio", true in all other cases.

Parameters:
showSubClauseButton - showSubClauseButton Default value is See Description
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getShowSubClauseButton

public Boolean getShowSubClauseButton()
Whether to show a button that allows the user to add subclauses. Defaults to false if the com.smartgwt.client..TopOperatorAppearance is "radio", true in all other cases.

Returns:
Boolean

setSubClauseButtonTitle

public void setSubClauseButtonTitle(String subClauseButtonTitle)
                             throws IllegalStateException
The hover title text of the subClauseButton

Parameters:
subClauseButtonTitle - subClauseButtonTitle Default value is "+()"
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getSubClauseButtonTitle

public String getSubClauseButtonTitle()
The hover title text of the subClauseButton

Returns:
String

setSubClauseButtonPrompt

public void setSubClauseButtonPrompt(String subClauseButtonPrompt)
                              throws IllegalStateException
The hover prompt text for the subClauseButton.

Parameters:
subClauseButtonPrompt - subClauseButtonPrompt Default value is "Add Subclause"
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getSubClauseButtonPrompt

public String getSubClauseButtonPrompt()
The hover prompt text for the subClauseButton.

Returns:
String

clearCriteria

public void clearCriteria()
Clear all current criteria.


addSearchHandler

public HandlerRegistration addSearchHandler(SearchHandler handler)
Add a search handler.

A StringMethod that is automatically invoked if saveOnEnter is set and the user presses Enter whilst in a text-item in any clause or subclause.

Specified by:
addSearchHandler in interface HasSearchHandlers
Parameters:
handler - the search handler
Returns:
HandlerRegistration used to remove this handler

addFilterChangedHandler

public HandlerRegistration addFilterChangedHandler(FilterChangedHandler handler)
Add a filterChanged handler.

Handler fired when there is a change() event fired on any FormItem within the filterBuilder.

Specified by:
addFilterChangedHandler in interface HasFilterChangedHandlers
Parameters:
handler - the filterChanged handler
Returns:
HandlerRegistration used to remove this handler

setShowFieldTitles

public void setShowFieldTitles(boolean showFieldTitles)
                        throws IllegalStateException
If true (the default), show field titles in the drop-down box used to select a field for querying. If false, show actual field names instead.

Parameters:
showFieldTitles - showFieldTitles default is true
Throws:
IllegalStateException - this property cannot be changed after the component has been created

setDataSource

public void setDataSource(DataSource dataSource)
DataSource this filter should use for field definitions and available ${isc.DocUtils.linkForRef('object:Operator')}s.

Parameters:
dataSource - dataSource Default value is null

getDataSource

public DataSource getDataSource()
The DataSource that this component should bind to for default fields and for performing DSRequest.

Can be specified as either a DataSource instance or the String ID of a DataSource.

Returns:
DataSource

setTopOperatorAppearance

public void setTopOperatorAppearance(TopOperatorAppearance topOperatorAppearance)
                              throws IllegalStateException
How to display and edit the topOperator for this FilterBuilder.

See TopOperatorAppearance for a list of options.

Parameters:
topOperatorAppearance - topOperatorAppearance Default value is "bracket"
Throws:
IllegalStateException - this property cannot be changed after the component has been created

setCriteria

public void setCriteria(AdvancedCriteria criteria)
Initial criteria.

When initialized with criteria, appropriate clauses for editing the provided criteria will be automatically generated.

Note that empty or partial criteria are allowed, for example, criteria that specify fieldName only will generate an expression with the operator not chosen yet, and a ${isc.DocUtils.linkForRef('object:Criterion')} with a logical operator ("and" or "or") but not ${isc.DocUtils.linkForRef('criteria.criteria','subcriteria')} defined will generate an empty subclause. Set new criteria for editing.

An interface for editing the provided criteria will be generated identically to what happens when initialized with Criteria.

Any existing criteria entered by the user will be discarded.

Parameters:
criteria - new criteria. Pass null or {} to effectively reset the filterBuilder to it's initial state when no criteria are specified. Default value is null

getCriteria

public AdvancedCriteria getCriteria()
Initial criteria.

When initialized with criteria, appropriate clauses for editing the provided criteria will be automatically generated.

Note that empty or partial criteria are allowed, for example, criteria that specify fieldName only will generate an expression with the operator not chosen yet, and a ${isc.DocUtils.linkForRef('object:Criterion')} with a logical operator ("and" or "or") but not ${isc.DocUtils.linkForRef('criteria.criteria','subcriteria')} defined will generate an empty subclause.

Returns:
Get the criteria entered by the user.