phpDocumentor GalleryCore
Classes
[ class tree: GalleryCore ] [ index: GalleryCore ] [ all elements ]

Class: GallerySortInterface_1_2

Source Location: /modules/core/classes/GallerySortInterface_1_2.class

Class GallerySortInterface_1_2

Class Overview

This is an interface for adding custom sort orders for displaying items.

Located in /modules/core/classes/GallerySortInterface_1_2.class [line 35]



		
				Author(s):
		
API Tags:
Abstract:  

Methods

[ Top ]
Direct descendents
Child Class Description
NewItemsSortOrder Presort to show new items first.
RatingSortOrder Sort by average rating.
ChildTestSortOrder Test sort order
ChildTestSortOrder2 Test sort order to verify self-join is avoided

[ Top ]
Method Summary
static array   getAllSortOrders()   Get information about available sort orders
array   getSortInfo()   Return information about this sort
array   getSortOrder()   Get the query fragments used to perform this sort.

[ Top ]
Methods
static method getAllSortOrders  [line 77]

  static array getAllSortOrders( [boolean $includeDefault = true]  )

Get information about available sort orders

Parameters:
boolean   $includeDefault:  (optional) false to omit "default sort order" selection

API Tags:
Return:  GalleryStatus a status code array of orderBy => localized name for sort orders array of orderBy => localized name for presorts array of orderDirection => localized name for direction


[ Top ]
getSortInfo  [line 44]

  array getSortInfo( )

Return information about this sort


API Tags:
Return:  GalleryStatus a status code string localized name boolean true for presort


Redefined in descendants as:

[ Top ]
getSortOrder  [line 63]

  array getSortOrder( string $direction  )

Get the query fragments used to perform this sort.

Order by clause may contain %1%, %2% or %3% to reference the corresponding items in the select clause. A join should be of the form: JOIN [Class] ON [BASE::ID] = [Class::Column] Replace "Class" and "Column" with appropriate values, but BASE::ID is literal. This references the base table and id column in the query.

Parameters:
string   $direction:  either '' for ascending or ' DESC' for descending

API Tags:
Return:  GalleryStatus a status code string order by clause string select clause, string optional row matching condition string optional join clause


Redefined in descendants as:

[ Top ]

Documentation generated on Fri, 08 Oct 2010 05:04:07 -0700 by phpDocumentor 1.3.0RC6