Class WFDieselFacet

Description

Implements interfaces:

A Dieselpoint Facet widget for our framework.

PHOCOA Builder Setup:

Required:

Optional:

  • todo: Implement multi-select facets: AND vs. OR.
  • todo: Implement TREEs.
  • todo: check out FacetGenerator.hasMore()... maybe good for long-ass lists. maybe switch from sortByFrequency to alpha once "more" clicked? use with popup edit
  • todo: Facets seem to be generating the link to themselves... is this a DP bug? Why would one want to show the current selection? Is it confusing?
  • todo: $facet used throughout our WFDieselFacet is actual an AttributeValue object. Confusing; need to re-name.
  • todo: treeRoot cookie trail linking isn't quite perfect yet...

Located in /framework/widgets/WFDieselFacet.php (line 39)

WFObject
   |
   --WFView
      |
      --WFWidget
         |
         --WFDieselFacet
Class Constant Summary
 STYLE_LIST = 'list'
 STYLE_MENU = 'menu'
 STYLE_TREE = 'tree'
Variable Summary
Method Summary
static void exposedProperties ()
WFDieselFacet __construct ( $id,  $page)
void attributeID ()
void editFacetLink ([ $linkText = "Edit"], [ $class = NULL])
void facetSelectionHTML ([ $maxLength = 40])
void facetStyle ()
void label ()
string path ()
void popupAttributeValueIsSelected ( $attributeValue)
array prepareFacets ()
void printAttributeValue ( $avArray, [ $indent = 0])
void removeFacetLink ([ $linkText = "Remove"])
void render ([ $blockContent = NULL])
void setAttributeId ( $id)
void setDieselSearchHelper ( $dsh)
void setFacetStyle ( $style)
void setIsPopup ( $b)
void setPopupSelections ( $selections)
void setRangeCount ( $rc)
void setShowItemCounts ( $show)
void setTreeDataPath ( $path)
Variables
string $attributeID (line 62)
  • var: The Dieselpoint attribute id that this facet shows.
  • access: protected
mixed $defaultTreePosition (line 58)
  • access: protected
object WFDieselSearchHelper $dieselSearchHelper (line 66)
  • var: The WFDieselSearchHelper object that this facet is linked to.
  • access: protected
integer $ellipsisAfterChars (line 104)
  • var: Number of chars after which the facet value string should be ellipsised. Default 0 (UNLIMITED).
  • access: protected
string $facetStyle (line 53)
  • var: The facet style. One of the WFDieselFacet::STYLE* constants.
  • access: protected
boolean $fakeOpenEndedRange (line 76)
  • var: True to implement fake open-ended ranges corrections. With DP < 4.0, there is no range supprort, so we fake it with multi-value attr categories. IE Bedrooms 1+, 2+, 3+. The downside of this is that the facets don't adjust as choices are selected (b/c 3+ includes 1+ and 2+). The fakeOpenEndedRange support will correct the facet display by eliminating choices less than the current value.
  • access: protected
mixed $isPopup (line 47)
  • access: protected
mixed $isTaxonomyAttribute (line 109)
  • access: protected
string $label (line 92)
  • var: The label to show for the facet.
  • access: protected
int $maxHits (line 84)
  • var: The maximum number of hits to count for each facet. Defaults to SHOW EXACT COUNT (Integer.MAX_VALUE). Set to a lower number if you don't care about more than a certain number, like 1000. Set to 1 for maxium performance. NOTE: setting showItemCounts to FALSE will automatically set maxHits to 1.
  • access: protected
int $maxRows (line 88)
  • var: The maximum number of facets to show. Defaults to -1, which means SHOW ALL ROWS.
  • access: protected
mixed $popupSelections (line 48)
  • access: protected
int $rangeCount (line 70)
  • var: The number of ranges to show for the facet. Presently this will create N facets each containing approximately equal numbers of items. Default is 0, which disables range mode.
  • access: protected
string $showAllText (line 100)
  • var: The text to display for the "Show All" link. Default is "Show All".
  • access: protected
boolean $showItemCounts (line 80)
  • var: If true, the number of items in each facet will be shown as well. Default is TRUE. Performance will be faster if this is set to FALSE.
  • access: protected
boolean $sortByFrequency (line 96)
  • var: If true, facets will be sorted by frequency of each facet. In this case, the facet with the most "hits" will be first, etc. If false, facets are sorted by the value they represent. Default is TRUE.
  • access: protected
string $treeDataPath (line 108)
  • var: For ajax callback of tree data... the path to the tree node whose kids need to be returned.
  • access: protected
string $treeRoot (line 57)
  • var: The root of the tree to start at. Only applies with STYLE_TREE. Default NULL (start at base).
  • access: protected
mixed $width (line 110)
  • access: protected

Inherited Variables

Inherited from WFWidget

WFWidget::$bindings
WFWidget::$class
WFWidget::$errors
WFWidget::$formatter
WFWidget::$hasRestoredState
WFWidget::$hidden
WFWidget::$name
WFWidget::$value
WFWidget::$widgetLabel

Inherited from WFView

WFView::$children
WFView::$cssImports
WFView::$enabled
WFView::$id
WFView::$importInHead
WFView::$jsActions
WFView::$jsEvents
WFView::$jsImports
WFView::$originalOnEvent
WFView::$page
WFView::$parent
Methods
static method exposedProperties (line 139)
  • access: public
static void exposedProperties ()

Redefinition of:
WFWidget::exposedProperties()
Constructor __construct (line 115)

Constructor.

WFDieselFacet __construct ( $id,  $page)
  • $id
  • $page

Redefinition of:
WFWidget::__construct()
Constructor.
allConfigFinishedLoading (line 623)
void allConfigFinishedLoading ()

Redefinition of:
WFView::allConfigFinishedLoading()
After WFPage has completed the loading of all config for all widgets, it will call this function on each widget.
attributeID (line 196)
void attributeID ()
canPushValueBinding (line 787)
void canPushValueBinding ()

Redefinition of:
WFWidget::canPushValueBinding()
Does this widget use the "value" binding to WRITE data back to the bindings?
dieselSearchRestoreState (line 602)
void dieselSearchRestoreState ()

Implementation of:
WFDieselSearchHelperStateTracking::dieselSearchRestoreState()
IFF the UI widget knows that its state was set in the interface, it should use addAttributeQuery/setSimpleQuery to effect this.
editFacetLink (line 516)
void editFacetLink ([ $linkText = "Edit"], [ $class = NULL])
  • $linkText
  • $class
facetSelectionHTML (line 452)
void facetSelectionHTML ([ $maxLength = 40])
  • $maxLength
facetStyle (line 186)
void facetStyle ()
label (line 191)
void label ()
path (line 231)

Path, for taxonomy facets. Takes into account treeRoot.

  • return: The current path.
  • throws: object Exception If not a taxonomy facet.
string path ()
popupAttributeValueIsSelected (line 628)
void popupAttributeValueIsSelected ( $attributeValue)
  • $attributeValue
prepareFacets (line 261)

Prepare the list of facets for the current widget.

  • return: An array of facet objects (via the java bridge)
  • throws: Excpetion if there are any errors.
array prepareFacets ()
printAttributeValue (line 772)
void printAttributeValue ( $avArray, [ $indent = 0])
  • $avArray
  • $indent
removeFacetLink (line 506)
void removeFacetLink ([ $linkText = "Remove"])
  • $linkText
render (line 350)
void render ([ $blockContent = NULL])
  • $blockContent

Redefinition of:
WFView::render()
Render the view into HTML.
setAttributeId (line 201)
void setAttributeId ( $id)
  • $id
setDieselSearchHelper (line 215)
void setDieselSearchHelper ( $dsh)
  • $dsh
setFacetStyle (line 180)
void setFacetStyle ( $style)
  • $style
setIsPopup (line 173)
void setIsPopup ( $b)
  • $b
setPopupSelections (line 165)
void setPopupSelections ( $selections)
  • $selections
setRangeCount (line 220)
void setRangeCount ( $rc)
  • $rc
setShowItemCounts (line 206)
void setShowItemCounts ( $show)
  • $show
setTreeDataPath (line 160)
void setTreeDataPath ( $path)
  • $path

Inherited Methods

Inherited From WFWidget

WFWidget::__construct()
WFWidget::addError()
WFWidget::addErrors()
WFWidget::bind()
WFWidget::bindingByName()
WFWidget::bindings()
WFWidget::canPushValueBinding()
WFWidget::errors()
WFWidget::exposedBindings()
WFWidget::exposedProperties()
WFWidget::formattedValue()
WFWidget::formatter()
WFWidget::hasRestoredState()
WFWidget::hidden()
WFWidget::name()
WFWidget::processBindingOptions()
WFWidget::propagateValueToBinding()
WFWidget::pullBindings()
WFWidget::pushBindings()
WFWidget::restoreState()
WFWidget::setFormatter()
WFWidget::setHidden()
WFWidget::setName()
WFWidget::setupExposedBindings()
WFWidget::setValue()
WFWidget::setWidgetLabel()
WFWidget::unbind()
WFWidget::value()
WFWidget::valueForBinding()
WFWidget::widgetLabel()

Inherited From WFView

WFView::__construct()
WFView::addChild()
WFView::allConfigFinishedLoading()
WFView::children()
WFView::cloneWithID()
WFView::enabled()
WFView::exposedProperties()
WFView::getForm()
WFView::getJSActions()
WFView::getListenerJS()
WFView::getListenerJSInScriptTag()
WFView::getOnEvent()
WFView::getWidgetDir()
WFView::getWidgetWWWDir()
WFView::id()
WFView::importCSS()
WFView::importJS()
WFView::jsEndHTML()
WFView::jsStartHTML()
WFView::page()
WFView::parent()
WFView::removeChild()
WFView::render()
WFView::setEnabled()
WFView::setId()
WFView::setJSonBlur()
WFView::setJSonClick()
WFView::setListener()
WFView::setOnEvent()
WFView::setParent()
WFView::yuiPath()

Inherited From WFObject

WFObject::__construct()
WFObject::exposedProperties()
WFObject::getClass()
WFObject::keyPathToTargetAndKey()
WFObject::setValueForKey()
WFObject::setValueForKeyPath()
WFObject::setValuesForKeys()
WFObject::validatedSetValueForKey()
WFObject::validatedSetValueForKeyPath()
WFObject::validateObject()
WFObject::validateValueForKey()
WFObject::validateValueForKeyPath()
WFObject::valueForKey()
WFObject::valueForKeyPath()
WFObject::valueForStaticKey()
WFObject::valueForStaticKeyPath()
WFObject::valueForTargetAndKeyPath()
WFObject::valueForUndefinedKey()
WFObject::valueForUndefinedStaticKey()
WFObject::valuesForKeyPaths()
WFObject::valuesForKeys()
WFObject::_valueForStaticKey()
WFObject::__toString()
Class Constants
STYLE_LIST = 'list' (line 41)
STYLE_MENU = 'menu' (line 42)
STYLE_TREE = 'tree' (line 43)
UNLIMITED_ROWS = 1000 (line 45)

Documentation generated on Thu, 14 May 2009 16:19:53 -0400 by phpDocumentor 1.4.2