PHP 클래스 Formo_Core_Innards

파일 보기 프로젝트 열기: bmidget/kohana-formo

보호된 프로퍼티들

프로퍼티 타입 설명
$_alias mixed The field alias
$_attr mixed Array of HTML attributes
$_blueprint boolean (default value: false)
$_blueprint_count integer (default value: 0)
$_blueprint_dynamic boolean (default value: false)
$_blueprint_pks aray (default value=: array())
$_blueprint_template mixed Allow for setting custom blueprint template separate from blueprint
$_callbacks array (default value: array())
$_config array (default value: array())
$_construct_aliases array Used at construct for reconciling variables
$_driver mixed Field's driver name
$_editable boolean (default value: true)
$_errors array (default value: array())
$_fields array (default value: array())
$_filters array (default value: array())
$_ftype string Used for auto-loading config defaults
$_html mixed HTML instide a tag
$_label mixed (default value: self::NOTSET)
$_opts array (default value: array())
$_parent mixed Field's parent object
$_render boolean (default value: true)
$_rules array (default value: array())
$_single_tags array HTML tags that don't have a closing
$_to_array_attrs mixed List of attributes that get copied by default in Formo::to_array()
$_vals mixed Keep track of field's values
$_vars array (default value: array())

공개 메소드들

메소드 설명
config ( mixed $param, mixed $default = NULL ) : void Find a config value.
range ( mixed $field, mixed $form ) : boolean Validation method that properly validates for html5 range

보호된 메소드들

메소드 설명
_add_rule ( array $rule ) : void Add a rule to a field.
_add_rules_to_validation ( Validation $validation ) : void Add rules to a validation object.
_arr_dotsyntax ( array $array ) : array Convert a multidmensional array to dot-syntax key values
_attr_to_str ( ) : void Turn attributes array into a string.
_error_to_msg ( array $errors_array = NULL ) : string Convert an error returned from the Validation object to a formatted message
_get_files_array ( array $files ) : array Convert $_FILES array to one Formo understands
_get_label ( $label = NULL ) : string Return the formatted string for a field.
_get_val ( ) : void Return a field's value.
_get_var_name ( mixed $var ) : string For set() and get(), return the variable name being set, and gotten
_is_blueprint_def ( Formo $parent = NULL, $test = false ) : void Determine whether a field is paret of a blueprint definition
_load ( array $array ) : void Load values into the form
_make_id ( ) : void Make an id for a field that doesn't already have one
_merge ( mixed $name, array $array ) : void Merge an array of values with another array of values
_order ( mixed $field_alias, mixed $new_order, mixed $relative_field = NULL ) : void Internal method to reorder fields
_remove_rule ( mixed $rule ) : void Search for and remove a rule if it exists
_reset ( ) : Formo Reset field values to their original values
_resolve_construct_aliases ( mixed $array ) : void Allow non-associative arrays to define a new field
_resolve_namespaced_files ( array $files ) : array Convert namespaced $_FILES array into values Formo can understand
_run_callbacks ( mixed $type = NULL ) : void Internal method to run all applicable callbacks
_set_driver ( mixed $driver ) : void Set a field's driver
_set_id ( array &$array ) : void Set a field's id attribute if the auto_id config setting is TRUE
_set_val ( mixed $val, mixed $force_new = FALSE ) : void Set the field's value
_setup_from_ftype ( ) : void Default field definitions from config file

메소드 상세

_add_rule() 보호된 메소드

Add a rule to a field.
protected _add_rule ( array $rule ) : void
$rule array
리턴 void

_add_rules_to_validation() 보호된 메소드

Add rules to a validation object.
protected _add_rules_to_validation ( Validation $validation ) : void
$validation Validation
리턴 void

_arr_dotsyntax() 보호된 메소드

Convert a multidmensional array to dot-syntax key values
protected _arr_dotsyntax ( array $array ) : array
$array array
리턴 array

_attr_to_str() 보호된 메소드

Turn attributes array into a string.
protected _attr_to_str ( ) : void
리턴 void

_error_to_msg() 보호된 메소드

Convert an error returned from the Validation object to a formatted message
protected _error_to_msg ( array $errors_array = NULL ) : string
$errors_array array (default: NULL)
리턴 string

_get_files_array() 보호된 메소드

Convert $_FILES array to one Formo understands
protected _get_files_array ( array $files ) : array
$files array
리턴 array

_get_label() 보호된 메소드

Return the formatted string for a field.
protected _get_label ( $label = NULL ) : string
리턴 string

_get_val() 보호된 메소드

Return a field's value.
protected _get_val ( ) : void
리턴 void

_get_var_name() 보호된 메소드

For set() and get(), return the variable name being set, and gotten
protected _get_var_name ( mixed $var ) : string
$var mixed
리턴 string

_is_blueprint_def() 보호된 메소드

Determine whether a field is paret of a blueprint definition
protected _is_blueprint_def ( Formo $parent = NULL, $test = false ) : void
$parent Formo (default: FALSE)
리턴 void

_load() 보호된 메소드

Load values into the form
protected _load ( array $array ) : void
$array array
리턴 void

_make_id() 보호된 메소드

Make an id for a field that doesn't already have one
protected _make_id ( ) : void
리턴 void

_merge() 보호된 메소드

Merge an array of values with another array of values
protected _merge ( mixed $name, array $array ) : void
$name mixed
$array array
리턴 void

_order() 보호된 메소드

Internal method to reorder fields
protected _order ( mixed $field_alias, mixed $new_order, mixed $relative_field = NULL ) : void
$field_alias mixed
$new_order mixed
$relative_field mixed (default: NULL)
리턴 void

_remove_rule() 보호된 메소드

Search for and remove a rule if it exists
protected _remove_rule ( mixed $rule ) : void
$rule mixed
리턴 void

_reset() 보호된 메소드

Reset field values to their original values
protected _reset ( ) : Formo
리턴 Formo obj

_resolve_construct_aliases() 보호된 메소드

Allow non-associative arrays to define a new field
protected _resolve_construct_aliases ( mixed $array ) : void
$array mixed
리턴 void

_resolve_namespaced_files() 보호된 메소드

Convert namespaced $_FILES array into values Formo can understand
protected _resolve_namespaced_files ( array $files ) : array
$files array
리턴 array

_run_callbacks() 보호된 메소드

Internal method to run all applicable callbacks
protected _run_callbacks ( mixed $type = NULL ) : void
$type mixed (default: NULL)
리턴 void

_set_driver() 보호된 메소드

Set a field's driver
protected _set_driver ( mixed $driver ) : void
$driver mixed
리턴 void

_set_id() 보호된 메소드

Set a field's id attribute if the auto_id config setting is TRUE
protected _set_id ( array &$array ) : void
$array array
리턴 void

_set_val() 보호된 메소드

Set the field's value
protected _set_val ( mixed $val, mixed $force_new = FALSE ) : void
$val mixed
$force_new mixed (default: FALSE)
리턴 void

_setup_from_ftype() 보호된 메소드

Default field definitions from config file
protected _setup_from_ftype ( ) : void
리턴 void

config() 공개 메소드

Find a config value.
public config ( mixed $param, mixed $default = NULL ) : void
$param mixed
$default mixed (default: NULL)
리턴 void

range() 공개 정적인 메소드

Validation method that properly validates for html5 range
public static range ( mixed $field, mixed $form ) : boolean
$field mixed
$form mixed
리턴 boolean

프로퍼티 상세

$_alias 보호되어 있는 프로퍼티

The field alias
protected mixed $_alias
리턴 mixed

$_attr 보호되어 있는 프로퍼티

Array of HTML attributes
protected mixed $_attr
리턴 mixed

$_blueprint 보호되어 있는 프로퍼티

(default value: false)
protected bool $_blueprint
리턴 boolean

$_blueprint_count 보호되어 있는 프로퍼티

(default value: 0)
protected int $_blueprint_count
리턴 integer

$_blueprint_dynamic 보호되어 있는 프로퍼티

(default value: false)
protected bool $_blueprint_dynamic
리턴 boolean

$_blueprint_pks 보호되어 있는 프로퍼티

(default value=: array())
protected aray $_blueprint_pks
리턴 aray

$_blueprint_template 보호되어 있는 프로퍼티

Allow for setting custom blueprint template separate from blueprint
protected mixed $_blueprint_template
리턴 mixed

$_callbacks 보호되어 있는 프로퍼티

(default value: array())
protected array $_callbacks
리턴 array

$_config 보호되어 있는 프로퍼티

(default value: array())
protected array $_config
리턴 array

$_construct_aliases 보호되어 있는 정적으로 프로퍼티

Used at construct for reconciling variables
protected static array $_construct_aliases
리턴 array

$_driver 보호되어 있는 프로퍼티

Field's driver name
protected mixed $_driver
리턴 mixed

$_editable 보호되어 있는 프로퍼티

(default value: true)
protected bool $_editable
리턴 boolean

$_errors 보호되어 있는 프로퍼티

(default value: array())
protected array $_errors
리턴 array

$_fields 보호되어 있는 프로퍼티

(default value: array())
protected array $_fields
리턴 array

$_filters 보호되어 있는 프로퍼티

(default value: array())
protected array $_filters
리턴 array

$_ftype 보호되어 있는 프로퍼티

Used for auto-loading config defaults
protected string $_ftype
리턴 string

$_html 보호되어 있는 프로퍼티

HTML instide a tag
protected mixed $_html
리턴 mixed

$_label 보호되어 있는 프로퍼티

(default value: self::NOTSET)
protected mixed $_label
리턴 mixed

$_opts 보호되어 있는 프로퍼티

(default value: array())
protected array $_opts
리턴 array

$_parent 보호되어 있는 프로퍼티

Field's parent object
protected mixed $_parent
리턴 mixed

$_render 보호되어 있는 프로퍼티

(default value: true)
protected bool $_render
리턴 boolean

$_rules 보호되어 있는 프로퍼티

(default value: array())
protected array $_rules
리턴 array

$_single_tags 보호되어 있는 정적으로 프로퍼티

HTML tags that don't have a closing
protected static array $_single_tags
리턴 array

$_to_array_attrs 보호되어 있는 정적으로 프로퍼티

List of attributes that get copied by default in Formo::to_array()
protected static mixed $_to_array_attrs
리턴 mixed

$_vals 보호되어 있는 프로퍼티

Keep track of field's values
protected mixed $_vals
리턴 mixed

$_vars 보호되어 있는 프로퍼티

(default value: array())
protected array $_vars
리턴 array