Class NSelectBox
Select box control that allows single item selection.
NObject | --NComponent | --NFormControl | --NSelectBox
Direct Known Sub-classes:
Public Method Summary | |
---|---|
NSelectBox |
|
bool |
areKeysUsed
()
Are the keys used?
|
NHtml |
getControl
()
Generates control's HTML element.
|
array |
getItems
()
Returns items from which to choose.
|
mixed |
getRawValue
()
Returns selected item key (not checked).
|
string |
Returns selected value.
|
mixed |
getValue
()
Returns selected item key.
|
bool |
Is first item in select box ignored?
|
NSelectBox |
setItems
($items, [$useKeys =
TRUE ])
Sets items from which to choose.
|
NSelectBox |
skipFirst
([string $item =
NULL ])
Ignores the first item in select box.
|
static bool |
validateFilled
(IFormControl $control)
Filled validator: has been any item selected?
|
Methods Inherited From NComponent |
---|
__construct(), attached(), detached(), getName(), getParent(), lookup(), lookupPath(), monitor(), setParent(), unmonitor(), validateParent(), __clone(), __wakeup() |
Methods Inherited From NObject |
---|
extensionMethod(), getClass(), getReflection(), __call(), __callStatic(), __get(), __isset(), __set(), __unset() |
Variable Summary | ||||
---|---|---|---|---|
protected array | $allowed | array() |
line 44 |
Method Details | ||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
line 59 __constructpublic NSelectBox __construct ([string $label =
|
||||||||||||||||||
line 136 areKeysUsedpublic bool areKeysUsed () Are the keys used?
|
||||||||||||||||||
line 211 getControlpublic NHtml getControl () Generates control's HTML element. Overridden in child classes as:
|
||||||||||||||||||
line 183 getItemspublic array getItems () Returns items from which to choose.
|
||||||||||||||||||
line 93 getRawValuepublic mixed getRawValue () Returns selected item key (not checked). Overridden in child classes as:
|
||||||||||||||||||
line 194 getSelectedItempublic string getSelectedItem () Returns selected value. Overridden in child classes as:
|
||||||||||||||||||
line 77 getValuepublic mixed getValue () Returns selected item key. Overridden in child classes as:
|
||||||||||||||||||
line 125 isFirstSkippedpublic bool isFirstSkipped () Is first item in select box ignored?
|
||||||||||||||||||
line 148 setItemspublic NSelectBox setItems ($items, [$useKeys = Sets items from which to choose.
|
||||||||||||||||||
line 105 skipFirstpublic NSelectBox skipFirst ([string $item = Ignores the first item in select box.
|
||||||||||||||||||
line 249 validateFilledpublic static bool validateFilled (IFormControl $control) Filled validator: has been any item selected?
|