PHP Class QListControl, qcodo

This object is the foundation for the ListBox, CheckBoxList, RadioButtonList and TreeNav.
Inheritance: extends QControl
Afficher le fichier Open project: qcodo/qcodo Class Usage Examples

Protected Properties

Свойство Type Description
$objItemsArray QListItem[]

Méthodes publiques

Méthode Description
AddItem ( mixed $mixListItemOrName, string $strValue = null, boolean $blnSelected = null, string $strItemGroup = null, string $strOverrideParameters = null ) : QListItem Allows you to add a QListItem to the QListControl at the end of the private objItemsArray.
AddItemAt ( integer $intIndex, QListItem $objListItem ) Allows you to add a QListItem to this QListControl at a specific location in the current item array
AddItems ( array $mixItemArray, mixed $mixSelectedValues = null, string $strItemGroup = null, string $strOverrideParameters = null ) Allows you to add an array of key/value pairs to the ListControl. Convenient especially for adding a list from a type table, e.g. by passing in SomeType::$NameArray. The list of seleted values can either be an array of values, or just a single value.
CountItems ( ) : integer Returns the count of items in this QListControl
GetAllItems ( ) : QListItem[] This will return an array of ALL the QQListItems associated with this QListControl.
GetItem ( $intIndex ) Gets the ListItem at a specific location in objItemsArray
RemoveAllItems ( ) Removes all the items in objItemsArray
RemoveItem ( $intIndex ) Removes a specific ListItem at a specific location in objItemsArray
__get ( $strName )
__set ( $strName, $mixValue )

Method Details

AddItem() public méthode

Allows you to add a QListItem to the QListControl at the end of the private objItemsArray.
public AddItem ( mixed $mixListItemOrName, string $strValue = null, boolean $blnSelected = null, string $strItemGroup = null, string $strOverrideParameters = null ) : QListItem
$mixListItemOrName mixed
$strValue string
$blnSelected boolean
$strItemGroup string
$strOverrideParameters string
Résultat QListItem

AddItemAt() public méthode

Allows you to add a QListItem to this QListControl at a specific location in the current item array
public AddItemAt ( integer $intIndex, QListItem $objListItem )
$intIndex integer the index of the location to add the new item to
$objListItem QListItem the item to add

AddItems() public méthode

Allows you to add an array of key/value pairs to the ListControl. Convenient especially for adding a list from a type table, e.g. by passing in SomeType::$NameArray. The list of seleted values can either be an array of values, or just a single value.
public AddItems ( array $mixItemArray, mixed $mixSelectedValues = null, string $strItemGroup = null, string $strOverrideParameters = null )
$mixItemArray array name/value pairs of QListItems to add to this QListControl
$mixSelectedValues mixed can be an array of selected values, or just an atomic value, that is selected (optional)
$strItemGroup string
$strOverrideParameters string

CountItems() public méthode

Returns the count of items in this QListControl
public CountItems ( ) : integer
Résultat integer

GetAllItems() public méthode

Please note that while each individual item can be altered, altering the array, itself, will not affect any change on the QListControl. So existing QQListItems may be modified, but to add / remove items from the QListControl, you should use AddItem() and RemoveItem().
public GetAllItems ( ) : QListItem[]
Résultat QListItem[]

GetItem() public méthode

Gets the ListItem at a specific location in objItemsArray
public GetItem ( $intIndex )

RemoveAllItems() public méthode

Removes all the items in objItemsArray
public RemoveAllItems ( )

RemoveItem() public méthode

Removes a specific ListItem at a specific location in objItemsArray
public RemoveItem ( $intIndex )

__get() public méthode

public __get ( $strName )

__set() public méthode

public __set ( $strName, $mixValue )

Property Details

$objItemsArray protected_oe property

protected QListItem[] $objItemsArray
Résultat QListItem[]