live_search.js

Summary
live_search.js
bbop.widget.display.live_searchAmiGO object to draw various UI elements that have to do with things dealing with a fully faceted searcher/browser.
Functions
live_searchContructor for the bbop.widget.display.live_search object.
‘bbop-widget-search_pane-spinner’,
Functions
show_checkboxes_pExternal function to show the item checkboxes in the use interface.
set_linkerSet the linker to be used when creating links.
set_handlerSet the handler to be used when dealing with displaying special fields.
selected_nameExternal function to show give the name of the input name group for the selectable items in the checkboxes (if they are being used).
setup_querySetup the free text query display under contructed tags for later population.
setup_sticky_filtersSetup sticky filters display under contructed tags for later population.
setup_current_filtersSetup current filters display under contructed tags for later population.
setup_accordionSetup the accordion skeleton under contructed tags for later population.
setup_resultsSetup basic results table using the class conf.
draw_user_buttons(Re)draw the user-defined buttons in the meta information area.
draw_metaDraw meta results.
draw_queryDraw the query widget.
reset_querySimply reset the query and then redraw (rebind) the query.
draw_sticky_filters(Re)draw the information on the sticky filter set.
draw_current_filters(Re)draw the information on the current filter set.
draw_accordion(Re)draw the information in the accordion controls/filters.
draw_resultsDraw results using hints from the golr class configuration.
draw_errorSomehow report an error to the user.
set_buttonsSet the list of buttons for display by changing the button definition hash list.
set_query_fieldSet the text in the search query field box.

bbop.widget.display.live_search

AmiGO object to draw various UI elements that have to do with things dealing with a fully faceted searcher/browser.

It is probably not particularly useful directly, but rather used as the framework for more specialized interfaces.

See Also

search_pane.js

Summary
Functions
live_searchContructor for the bbop.widget.display.live_search object.

Functions

live_search

bbop.widget.display.live_search = function(interface_id,
conf_class)

Contructor for the bbop.widget.display.live_search object.

Arguments

interface_idstring id of the div to build on
conf_classbbop.golr.conf_class for hints and other settings

Returns

BBOP GOlr UI object

‘bbop-widget-search_pane-spinner’,

Summary
Functions
show_checkboxes_pExternal function to show the item checkboxes in the use interface.
set_linkerSet the linker to be used when creating links.
set_handlerSet the handler to be used when dealing with displaying special fields.
selected_nameExternal function to show give the name of the input name group for the selectable items in the checkboxes (if they are being used).
setup_querySetup the free text query display under contructed tags for later population.
setup_sticky_filtersSetup sticky filters display under contructed tags for later population.
setup_current_filtersSetup current filters display under contructed tags for later population.
setup_accordionSetup the accordion skeleton under contructed tags for later population.
setup_resultsSetup basic results table using the class conf.
draw_user_buttons(Re)draw the user-defined buttons in the meta information area.
draw_metaDraw meta results.
draw_queryDraw the query widget.
reset_querySimply reset the query and then redraw (rebind) the query.
draw_sticky_filters(Re)draw the information on the sticky filter set.
draw_current_filters(Re)draw the information on the current filter set.
draw_accordion(Re)draw the information in the accordion controls/filters.
draw_resultsDraw results using hints from the golr class configuration.
draw_errorSomehow report an error to the user.
set_buttonsSet the list of buttons for display by changing the button definition hash list.
set_query_fieldSet the text in the search query field box.

Functions

show_checkboxes_p

this.show_checkboxes_p = function(new_setting)

External function to show the item checkboxes in the use interface.

Parameters

new_setting[optional] show or not; defaults to false

Returns

true/false--the current state of showing the select boxes

set_linker

this.set_linker = function(linker)

Set the linker to be used when creating links.  If not set, a null function is used.

Parameters

linkerthe linker function to be used

Returns

true/false on whether it was properly set

set_handler

this.set_handler = function(handler)

Set the handler to be used when dealing with displaying special fields.  If not set, a null function is used.

Parameters

handlerthe handler function to be used

Returns

true/false on whether it was properly set

selected_name

this.selected_name = function()

External function to show give the name of the input name group for the selectable items in the checkboxes (if they are being used).  Null otherwise.

Keep in mind that this variable changes every times that the results table refreshes.

Parameters

n/a

Returns

string or null

setup_query

this.setup_query = function(label_str,
icon_clear_label,
icon_clear_source)

Setup the free text query display under contructed tags for later population.

If no icon_clear_source is defined, icon_clear_label will be used as the defining text.

Parameters

label_str[optional] string or bbop.html for input label
icon_clear_label[optional] string or bbop.html for clear icon
icon_clear_source[optional] string to define the src of img

Returns

n/a

setup_sticky_filters

this.setup_sticky_filters = function()

Setup sticky filters display under contructed tags for later population.  The seeding information is coming in through the GOlr conf class.

Add in the filter state up here.

Parameters

n/a

Returns

n/a

setup_current_filters

this.setup_current_filters = function(icon_remove_label,
icon_remove_source)

Setup current filters display under contructed tags for later population.  The seeding information is coming in through the GOlr conf class.

Add in the filter state up here.

If no icon_reset_source is defined, icon_reset_label will be used as the defining text.

Parameters

icon_remove_label[optional] string or bbop.html for remove icon
icon_remove_source[optional] string to define the src of img

Returns

n/a

setup_accordion

this.setup_accordion = function(icon_positive_label,
icon_positive_source,
icon_negative_label,
icon_negative_source,
spinner_shield_source,
spinner_shield_message)

Setup the accordion skeleton under contructed tags for later population.  The seeding information is coming in through the GOlr conf class.  Start building the accordion here.  Not an updatable part.

If no icon_*_source is defined, icon_*_label will be used as the defining text.

Parameters

icon_positive_label[optional] string or bbop.html for positive icon
icon_positive_source[optional] string to define the src of img
icon_negative_label[optional] string or bbop.html for positive icon
icon_negative_source[optional] string to define the src of img
spinner_shield_source[optional] string to define the src of img
spinner_shield_message[optional] string or bbop.html for message

Returns

n/a

setup_results

this.setup_results = function(args)

Setup basic results table using the class conf.  For actual results rendering, see .draw_results.  While there is a meta block supplied, its use is optional.

Argument hash entries

metadraw the meta-results; defaults to false
spinner_sourcethe source of the image to use for the activity spinner

Parameters

hash; see above for details

Returns

n/a

draw_user_buttons

this.draw_user_buttons = function(manager)

(Re)draw the user-defined buttons in the meta information area.  Will naturally fail if there is no meta div that has been nested with the user button element.

Parameters

managerbbop.golr.manager that we initially registered with

Returns

n/a

draw_meta

this.draw_meta = function(response,
manager)

Draw meta results.  Includes selector for drop down.

(Re)draw the count control with the current information in the manager.  This also tries to set the selector to the response number (to keep things in sync), unbinds any current “change” event, and adds a new change event.

Parameters

responsethe bbop.golr.response returned from the server
managerbbop.golr.manager that we initially registered with

Returns

n/a

draw_query

this.draw_query = function(response,
manager)

Draw the query widget.  This function makes it active as well.

Clicking the reset button will reset the query to ‘’.

NOTE: Since this is part of the “persistant” interface (i.e. it does not get wiped after every call), we make sure to clear the event listeners when we redraw the function to prevent them from building up.

Parameters

responsethe bbop.golr.response returned from the server
managerbbop.golr.manager that we initially registered with

Returns

n/a

reset_query

this.reset_query = function(response,
manager)

Simply reset the query and then redraw (rebind) the query.

Parameters

responsethe bbop.golr.response returned from the server
managerbbop.golr.manager that we initially registered with

Returns

n/a

See

draw_query

draw_sticky_filters

this.draw_sticky_filters = function(response,
manager)

(Re)draw the information on the sticky filter set.

Parameters

responsethe bbop.golr.response returned from the server
managerbbop.golr.manager that we initially registered with

Returns

n/a

draw_current_filters

this.draw_current_filters = function(response,
manager)

(Re)draw the information on the current filter set.  This function makes them active as well.

Parameters

responsethe bbop.golr.response returned from the server
managerbbop.golr.manager that we initially registered with

Returns

n/a

draw_accordion

this.draw_accordion = function(response,
manager)

(Re)draw the information in the accordion controls/filters.  This function makes them active as well.

Parameters

responsethe bbop.golr.response returned from the server
managerbbop.golr.manager that we initially registered with

Returns

n/a

draw_results

this.draw_results = function(response,
manager)

Draw results using hints from the golr class configuration.

Parameters

responsethe bbop.golr.response returned from the server
managerbbop.golr.manager that we initially registered with

Returns

n/a

draw_error

this.draw_error = function(error_message,
manager)

Somehow report an error to the user.

Parameters

error_messagea string(?) describing the error
managerbbop.golr.manager that we initially registered with

Returns

n/a

set_buttons

this.set_buttons = function(button_def_list)

Set the list of buttons for display by changing the button definition hash list.

If no buttons are set, the list is cleared.

Parameters

button_def_list[optional]

Returns

n/a

set_query_field

this.set_query_field = function(query)

Set the text in the search query field box.

If no query is set, the field is cleared.

Parameters

query[optional] string

Returns

true or false on whether the task was accomplished

bbop.widget.display.live_search = function(interface_id,
conf_class)
Contructor for the bbop.widget.display.live_search object.
this.show_checkboxes_p = function(new_setting)
External function to show the item checkboxes in the use interface.
this.set_linker = function(linker)
Set the linker to be used when creating links.
this.set_handler = function(handler)
Set the handler to be used when dealing with displaying special fields.
this.selected_name = function()
External function to show give the name of the input name group for the selectable items in the checkboxes (if they are being used).
this.setup_query = function(label_str,
icon_clear_label,
icon_clear_source)
Setup the free text query display under contructed tags for later population.
this.setup_sticky_filters = function()
Setup sticky filters display under contructed tags for later population.
this.setup_current_filters = function(icon_remove_label,
icon_remove_source)
Setup current filters display under contructed tags for later population.
this.setup_accordion = function(icon_positive_label,
icon_positive_source,
icon_negative_label,
icon_negative_source,
spinner_shield_source,
spinner_shield_message)
Setup the accordion skeleton under contructed tags for later population.
this.setup_results = function(args)
Setup basic results table using the class conf.
this.draw_user_buttons = function(manager)
(Re)draw the user-defined buttons in the meta information area.
this.draw_meta = function(response,
manager)
Draw meta results.
this.draw_query = function(response,
manager)
Draw the query widget.
this.reset_query = function(response,
manager)
Simply reset the query and then redraw (rebind) the query.
this.draw_sticky_filters = function(response,
manager)
(Re)draw the information on the sticky filter set.
this.draw_current_filters = function(response,
manager)
(Re)draw the information on the current filter set.
this.draw_accordion = function(response,
manager)
(Re)draw the information in the accordion controls/filters.
this.draw_results = function(response,
manager)
Draw results using hints from the golr class configuration.
this.draw_error = function(error_message,
manager)
Somehow report an error to the user.
this.set_buttons = function(button_def_list)
Set the list of buttons for display by changing the button definition hash list.
this.set_query_field = function(query)
Set the text in the search query field box.
Generic BBOP manager for dealing with gross GOlr configuration and management.
Generic BBOP handler for dealing with the gross parsing of responses from a GOlr server (whereas golr_conf deals with the reported configuration).
Close