Yioop_V9.5_Source_Code_Documentation

SearchView extends ComponentView
in package

Web page used to present search results It is also contains the search box for people to types searches into

Tags
author

Chris Pollett

Table of Contents

$controller_object  : object
The name of the type of controller object that is sending data to the view
$element_instances  : array<string|int, mixed>
Array of Element's that have been instantiated for this View
$head_objects  : array<string|int, mixed>
Meta info for group wiki pages
$helper_instances  : array<string|int, mixed>
Array of Helper's that have been instantiated for this View
$layout  : string
This view is drawn on a web layout
$layout_object  : object
The reference to the layout object that the view is drawn on
$logo_alt_text  : string
Logo image text name
$page_objects  : array<string|int, mixed>
Contents of group wiki pages
$containers  : array<string|int, mixed>
Containers for Elements that this ComponentView has
__construct()  : mixed
The constructor adds to its container all the objects needed to draw a search landing or result page
addContainer()  : mixed
Adds an Element object to the ComponentView container so it can be drawn in that container later.
element()  : mixed
Dynamic loader for Element objects which might live on the current View
emptyContainer()  : bool
Checks if one the top, sub-top,same, opposite, center or bottom contains has anything in it or not.
helper()  : mixed
Dynamic loader for Helper objects which might live on the current View
render()  : mixed
This method is responsible for drawing both the layout and the view. It should not be modified to change the display of the view (in subclasses).
renderContainer()  : mixed
Draws one of the container labels onto the view using data provided by the controller
renderView()  : mixed
This abstract method is implemented in sub classes with code which actually draws the view. The current layouts render method calls this function.

Properties

$controller_object

The name of the type of controller object that is sending data to the view

public object $controller_object = null

$element_instances

Array of Element's that have been instantiated for this View

public array<string|int, mixed> $element_instances

$head_objects

Meta info for group wiki pages

public array<string|int, mixed> $head_objects

$helper_instances

Array of Helper's that have been instantiated for this View

public array<string|int, mixed> $helper_instances

$layout

This view is drawn on a web layout

public string $layout = "web"

$layout_object

The reference to the layout object that the view is drawn on

public object $layout_object

$logo_alt_text

Logo image text name

public string $logo_alt_text

$page_objects

Contents of group wiki pages

public array<string|int, mixed> $page_objects

$containers

Containers for Elements that this ComponentView has

private array<string|int, mixed> $containers = []

Methods

__construct()

The constructor adds to its container all the objects needed to draw a search landing or result page

public __construct([object $controller_object = null ]) : mixed
Parameters
$controller_object : object = null

that is using this view

Return values
mixed

addContainer()

Adds an Element object to the ComponentView container so it can be drawn in that container later.

public addContainer(string $label, string $element_name) : mixed
Parameters
$label : string

name of the container on this component view to add the element to

$element_name : string

name of the Element (for example, for a GroupoptionsElement this name would be groupoptions) to instantiate and add to the container

Return values
mixed

element()

Dynamic loader for Element objects which might live on the current View

public element(string $element) : mixed
Parameters
$element : string

name of Element to return

Return values
mixed

emptyContainer()

Checks if one the top, sub-top,same, opposite, center or bottom contains has anything in it or not.

public emptyContainer(string $label) : bool
Parameters
$label : string

one of labels top, sub-top, etc

Return values
bool

whether that container is empty or not

helper()

Dynamic loader for Helper objects which might live on the current View

public helper(string $helper) : mixed
Parameters
$helper : string

name of Helper to return

Return values
mixed

render()

This method is responsible for drawing both the layout and the view. It should not be modified to change the display of the view (in subclasses).

public render(array<string|int, mixed> $data) : mixed

Instead, implement renderView.

Parameters
$data : array<string|int, mixed>

an array of values set up by a controller to be used in rendering the view

Return values
mixed

renderContainer()

Draws one of the container labels onto the view using data provided by the controller

public renderContainer(string $label, array<string|int, mixed> $data) : mixed
Parameters
$label : string

container to draw

$data : array<string|int, mixed>

field data from the controller for use during drawing

Return values
mixed

renderView()

This abstract method is implemented in sub classes with code which actually draws the view. The current layouts render method calls this function.

public abstract renderView(array<string|int, mixed> $data) : mixed
Parameters
$data : array<string|int, mixed>

an array of values set up by a controller to be used in rendering the view

Return values
mixed

        

Search results