b2evolution

Multilingual multiuser multiblog engine

b2evolution Technical Documentation (CVS HEAD) [ class tree: evocore ] [ index: evocore ] [ all elements ]

Class: ComponentWidget

Source Location: /blogs/inc/widgets/model/_widget.class.php

Class ComponentWidget

Direct descendents
Child Class Description
coll_avatar_Widget coll_avatar_Widget Class.
coll_xml_feeds_Widget ComponentWidget Class
coll_longdesc_Widget ComponentWidget Class
coll_title_Widget ComponentWidget Class
menu_link_Widget ComponentWidget Class
user_tools_Widget ComponentWidget Class
coll_media_index_Widget ComponentWidget Class
coll_category_list_Widget ComponentWidget Class
coll_common_links_Widget ComponentWidget: Common navigation links.
colls_list_owner_Widget ComponentWidget Class
coll_comment_list_Widget ComponentWidget Class
coll_search_form_Widget ComponentWidget Class
colls_list_public_Widget ComponentWidget Class
coll_logo_Widget ComponentWidget Class
coll_tagline_Widget ComponentWidget Class
free_html_Widget ComponentWidget Class
coll_item_list_Widget ComponentWidget Class
coll_tag_cloud_Widget ComponentWidget Class

[ Top ]
Inherited Properties, Constants, and Methods
Inherited Properties Inherited Methods Inherited Constants

Inherited From DataObject

DataObject::$allow_ID_insert
DataObject::$delete_cascades
DataObject::$delete_restrictions
DataObject::$ID

Inherited From DataObject

DataObject::DataObject()
Constructor
DataObject::action_icon()
Generate requested action icon depending on perm
DataObject::action_link()
Generate requested action link depending on perm
DataObject::check_delete()
Check relations for restrictions before deleting
DataObject::check_relations()
Check relations for restrictions or cascades.
DataObject::confirm_delete()
Displays form to confirm deletion of this object
DataObject::dbchange()
Records a change that will need to be updated in the db
DataObject::dbdelete()
Delete object from DB.
DataObject::dbexists()
Check existence of specified value in unique field.
DataObject::dbinsert()
Insert object into DB based on previously recorded changes.
DataObject::dbsave()
Inserts or Updates depending on object state.
DataObject::dbupdate()
Update the DB based on previously recorded changes
DataObject::dget()
Get a ready-to-display member param by its name
DataObject::disp()
Display a member param by its name
DataObject::get()
Get a member param by its name
DataObject::get_action_title()
Generate help title text for action
DataObject::history_info_icon()
Create icon with dataobject history
DataObject::ID()
Template function: Displays object ID.
DataObject::set()
Set param value
DataObject::set_from_Request()
Set a parameter from a Request form value.
DataObject::set_param()
Set param value.
DataObject::set_string_from_param()
Set a string parameter from a Request form value.

[ Top ]
Property Summary
mixed   $code  
mixed   $coll_ID  
mixed   $disp_params   Array of params used during display()
boolean   $enabled   Indicates whether the widget is enabled.
mixed   $order  
mixed   $params  
mixed   $param_array   Array of params which have been customized for this widget instance
Plugin   $Plugin   Lazy instantiated
mixed   $sco_name   Container name
string   $type  

[ Top ]
Method Summary
ComponentWidget   ComponentWidget()   Constructor
boolean   dbinsert()   Insert object into DB based on previously recorded changes.
void   dbupdate()   Update the DB based on previously recorded changes
void   display()   Display the widget!
void   display_with_cache()   Wraps display in a cacheable block.
void   disp_coll_list()   List of collections/blogs
void   disp_title()   Note: a container can prevent display of titles with 'block_display_title' This is useful for the lists in the headers fp> I'm not sur if this param should be overridable by widgets themselves (priority problem) Maybe an "auto" setting.
array   get_cache_keys()   Maybe be overriden by some widgets, depending on what THEY depend on..
void   get_desc()   Get desc of widget
void   get_desc_for_list()   Get a clean description to display in the widget list
void   get_name()   Get name of widget
void   get_param()   param value
void   get_param_definitions()   Get definitions for editable params
Plugin   &get_Plugin()   Get ref to Plugin handling this Widget
void   get_short_desc()   Get a very short desc. Used in the widget list.
void   init_display()   Prepare display params
void   load_from_Request()   Load params
void   load_param_array()   Load param array
boolean   set()   Set param value

[ Top ]
Properties
mixed   $code [line 49]

[ Top ]
mixed   $coll_ID [line 39]

[ Top ]
mixed   $disp_params = NULL [line 69]

Array of params used during display()


[ Top ]
boolean   $enabled [line 57]

Indicates whether the widget is enabled.


[ Top ]
mixed   $order [line 44]

[ Top ]
mixed   $params [line 50]

[ Top ]
mixed   $param_array = NULL [line 64]

Array of params which have been customized for this widget instance

This is saved to the DB as a serialized string ($params)


[ Top ]
Plugin   $Plugin [line 77]

Lazy instantiated

(false if this Widget is not handled by a Plugin)

API Tags:
See:  ComponentWidget::get_Plugin()


[ Top ]
mixed   $sco_name [line 43]

Container name


[ Top ]
string   $type [line 48]

[ Top ]
Methods
Constructor ComponentWidget  [line 85]

  ComponentWidget ComponentWidget( [object data $db_row = NULL], [ $type = 'core'], [ $code = NULL]  )

Constructor

Parameters:
object data   $db_row:  row from db
   $type: 
   $code: 


[ Top ]
dbinsert  [line 655]

  boolean dbinsert( )

Insert object into DB based on previously recorded changes.


API Tags:
Return:  true on success


Redefinition of:
DataObject::dbinsert()
Insert object into DB based on previously recorded changes.

[ Top ]
dbupdate  [line 685]

  void dbupdate( )

Update the DB based on previously recorded changes



Redefinition of:
DataObject::dbupdate()
Update the DB based on previously recorded changes

[ Top ]
display  [line 432]

  void display( array $params  )

Display the widget!

Should be overriden by core widgets

Parameters:
array   $params:  MUST contain at least the basic display params

Information Tags:
Todo:  fp> handle custom params for each widget

Redefined in descendants as:

[ Top ]
display_with_cache  [line 470]

  void display_with_cache( array $params, [array $keys = array()]  )

Wraps display in a cacheable block.

Parameters:
array   $params:  MUST contain at least the basic display params
array   $keys:  of extra keys to be used for cache keying

Information Tags:
Todo:  dh> I think Widgets need to provide caching, e.g. by returning something in cache_keys (so ComponentWidget::get_cache_keys() should return an empty list or false by default). fp> I don't understand what you mean.

[ Top ]
disp_coll_list  [line 550]

  void disp_coll_list( [array $filter = 'public']  )

List of collections/blogs

Parameters:
array   $filter:  MUST contain at least the basic display params


[ Top ]
disp_title  [line 529]

  void disp_title( [ $title = NULL]  )

Note: a container can prevent display of titles with 'block_display_title' This is useful for the lists in the headers fp> I'm not sur if this param should be overridable by widgets themselves (priority problem) Maybe an "auto" setting.

Parameters:
   $title: 


[ Top ]
get_cache_keys  [line 510]

  array get_cache_keys( )

Maybe be overriden by some widgets, depending on what THEY depend on..


API Tags:
Return:  of keys this widget depends on


Redefined in descendants as:

[ Top ]
get_desc  [line 210]

  void get_desc( )

Get desc of widget

Should be overriden by core widgets



Redefined in descendants as:

[ Top ]
get_desc_for_list  [line 185]

  void get_desc_for_list( )

Get a clean description to display in the widget list



[ Top ]
get_name  [line 155]

  void get_name( )

Get name of widget

Should be overriden by core widgets



Redefined in descendants as:

[ Top ]
get_param  [line 280]

  void get_param( $parname  )

param value

Parameters:
   $parname: 


[ Top ]
get_param_definitions  [line 232]

  void get_param_definitions( local $params  )

Get definitions for editable params

Parameters:
local   $params:  params like 'for_editing' => true

API Tags:
See:  Plugin::GetDefaultSettings()


Redefined in descendants as:

[ Top ]
get_Plugin  [line 115]

  Plugin &get_Plugin( )

Get ref to Plugin handling this Widget



[ Top ]
get_short_desc  [line 176]

  void get_short_desc( )

Get a very short desc. Used in the widget list.

MAY be overriden by core widgets. Example: menu link widget.



Redefined in descendants as:

[ Top ]
init_display  [line 334]

  void init_display( array $params  )

Prepare display params

Parameters:
array   $params:  MUST contain at least the basic display params

Information Tags:
Todo:  Document default params and default values. This might link to a wiki page, too.

Redefined in descendants as:

[ Top ]
load_from_Request  [line 138]

  void load_from_Request( )

Load params



Redefined in descendants as:

[ Top ]
load_param_array  [line 262]

  void load_param_array( )

Load param array



[ Top ]
set  [line 307]

  boolean set( string $parname, mixed $parvalue, [boolean $make_null = false]  )

Set param value

Parameters:
string   $parname:  parameter name
mixed   $parvalue:  parameter value
boolean   $make_null:  true to set to NULL if empty value

API Tags:
Return:  true, if a value has been set; false if it has not changed


Redefinition of:
DataObject::set()
Set param value

[ Top ]

Documentation generated on Sat, 06 Mar 2010 04:27:46 +0100 by phpDocumentor 1.4.2. This site is hosted and maintained by Daniel HAHLER (Contact).