nyroFwk  0.2
Public Member Functions | Protected Member Functions | Protected Attributes
form_list Class Reference
Inheritance diagram for form_list:
form_mulValue form_abstract object

Public Member Functions

 getValue ($outside=true)
 
 getValue ()
 
 setValue ($value, $refill=false)
 
 to ($type)
 
 toHtml ()
 
 toXul ()
 
 isInValue ($val)
 
 isDisabled ($val)
 
 renew ()
 
 getName ()
 
getRawValue ()
 
 getDescription ()
 
 getValid ()
 
 isValid ()
 
 getValidRule ($name)
 
 setDisabled ($disabled)
 
 getErrors ()
 
 addCustomError ($error)
 
 addRule ($type, $prm=null)
 
 delRule ($type)
 
 isHidden ()
 
 getType ()
 
 __toString ()
 
 __get ($name)
 
 __set ($name, $val)
 
 getAttr ($name)
 
 setAttr ($name, $value)
 
 getCfg ()
 

Protected Member Functions

 afterInit ()
 
 updateLine ($type, $val, $line)
 
 makeId ($name)
 
 initValid ()
 
 beforeInit ()
 

Protected Attributes

 $valid
 
 $customErrors = array()
 
 $cfg
 

Detailed Description

Form list element

Definition at line 10 of file list.class.php.

Member Function Documentation

◆ __get()

__get (   $name)
inherited

Get a variable directly from the configuration, with a convenient way $config->name

Parameters
string$nameValue requested
Returns
mixed The value requested, null if it doesn't exists

Definition at line 263 of file form/abstract.class.php.

◆ __set()

__set (   $name,
  $val 
)
inherited

Set a variable directly from the configuration, with a convenient way $config->name = $value

Parameters
string$nameValue requested
mixed$valueValue to set

Definition at line 273 of file form/abstract.class.php.

◆ __toString()

__toString ( )
inherited

Transform the element to a string to be shown, with the courant output

Returns
string

Definition at line 253 of file form/abstract.class.php.

◆ addCustomError()

addCustomError (   $error)
inherited

Add a custom error

Parameters
string$errorThe error text

Definition at line 185 of file form/abstract.class.php.

◆ addRule()

addRule (   $type,
  $prm = null 
)
inherited

Add a rule from the valdiation

Parameters
string$typeValidation type
array$prmParameter for this rule

Definition at line 195 of file form/abstract.class.php.

◆ afterInit()

afterInit ( )
protected

Definition at line 12 of file list.class.php.

◆ beforeInit()

beforeInit ( )
protectedinherited

Call just before the configuration initialisation

Definition at line 35 of file object.class.php.

◆ delRule()

delRule (   $type)
inherited

Delete a rule from the valdiation

Parameters
string$typeValidation type

Definition at line 204 of file form/abstract.class.php.

◆ getAttr()

getAttr (   $name)
inherited

Get an attribute

Parameters
string$nameAttribute name
Returns
mixed|null The attribute or null if not set

Definition at line 48 of file object.class.php.

◆ getCfg()

getCfg ( )
inherited

Get the configuration object

Returns
config

Definition at line 67 of file object.class.php.

◆ getDescription()

getDescription ( )
inherited

Get the description field

Returns
string

Definition at line 105 of file form/abstract.class.php.

◆ getErrors()

getErrors ( )
inherited

Get all the errors for the last validation

Returns
array

Definition at line 176 of file form/abstract.class.php.

◆ getName()

getName ( )
inherited

Get the field name

Returns
string

Definition at line 66 of file form/abstract.class.php.

◆ getRawValue()

& getRawValue ( )
inherited

Get the raw value

Returns
mixed

Definition at line 84 of file form/abstract.class.php.

◆ getType()

getType ( )
inherited

Get the form element type

Returns
string

Definition at line 222 of file form/abstract.class.php.

◆ getValid()

getValid ( )
inherited

Get the valid object

Returns
valid

Definition at line 132 of file form/abstract.class.php.

◆ getValidRule()

getValidRule (   $name)
inherited

Get a valide rule config

Parameters
string$nameRule name
Returns
null|mixed Null if not set or configuration if existing

Definition at line 151 of file form/abstract.class.php.

◆ getValue() [1/2]

getValue (   $outside = true)
inherited

Get the actual value

Parameters
bool$outsideIndicate if it's coming from outside (ie if it should be htmlDeOut)
Returns
mixed

Definition at line 67 of file mulValue.class.php.

◆ getValue() [2/2]

getValue ( )
inherited

Get the actual value

Returns
mixed

Definition at line 75 of file form/abstract.class.php.

◆ initValid()

initValid ( )
protectedinherited

Set the validation rules

Definition at line 115 of file form/abstract.class.php.

◆ isDisabled()

isDisabled (   $val)
inherited

Check if an option is disabled in configuration

Parameters
mixed$valbool

Definition at line 198 of file mulValue.class.php.

◆ isHidden()

isHidden ( )
inherited

Check if the element is hidden

Returns
bool

Definition at line 213 of file form/abstract.class.php.

◆ isInValue()

isInValue (   $val)
inherited

Check if a value is in the current value

Parameters
mixed$val
Returns
bool

Definition at line 185 of file mulValue.class.php.

◆ isValid()

isValid ( )
inherited

Check if the element is valid by using the valid object

Returns
bool True if valid

Definition at line 141 of file form/abstract.class.php.

◆ makeId()

makeId (   $name)
protectedinherited

Make a valid id from a name

Parameters
string$name
Returns
string

Definition at line 55 of file form/abstract.class.php.

◆ renew()

renew ( )
inherited

Definition at line 45 of file form/abstract.class.php.

◆ setAttr()

setAttr (   $name,
  $value 
)
inherited

Set an attribute

Parameters
string$nameAttribute name
mixed$valueAttribute value

Definition at line 58 of file object.class.php.

◆ setDisabled()

setDisabled (   $disabled)
inherited

Set the disabled state

Parameters
boolean$disabled

Definition at line 163 of file form/abstract.class.php.

◆ setValue()

setValue (   $value,
  $refill = false 
)
inherited

Definition at line 80 of file mulValue.class.php.

◆ to()

to (   $type)
inherited

Definition at line 88 of file mulValue.class.php.

◆ toHtml()

toHtml ( )
inherited

Definition at line 171 of file mulValue.class.php.

◆ toXul()

toXul ( )
inherited

Definition at line 175 of file mulValue.class.php.

◆ updateLine()

updateLine (   $type,
  $val,
  $line 
)
protectedinherited

Update a line before adding to the out

Parameters
string$typeOut type
mixed$valThe line value
string$lineThe current line
Returns
string The updated line

Definition at line 167 of file mulValue.class.php.

Field Documentation

◆ $cfg

$cfg
protectedinherited

Definition at line 17 of file object.class.php.

◆ $customErrors

$customErrors = array()
protectedinherited

Definition at line 24 of file form/abstract.class.php.

◆ $valid

$valid
protectedinherited

Definition at line 17 of file form/abstract.class.php.


The documentation for this class was generated from the following file:
Generated on Sun Oct 15 2017 22:25:20 for nyroFwk by doxygen 1.8.13