Gumbo_Input



Input Class

Author(s): Michael Luster <mluster79@yahoo.com>
License:New BSD License
Copyright:Copyright (c) 2007, iBayou, Michael Luster
Link:http://sourceforge.net/projects/phpgumbo
Version:0.0.1

Implements interfaces:

Class Variables

bool $_checked =  false [line 51]
bool $_clean =  false [line 49]
Gumbo_Interface_Constraint $_constraints = array () [line 39]
array $_constraints_return = array () [line 41]
mixed $_data_clean [line 46]
mixed $_data_raw [line 44]
bool $_run_thru =  true [line 53]

Class Methods

public Gumbo_Input __construct ( [mixed $data] ) [line 61]

Constructor

Parameter(s):

  • (mixed) $data :: data to be checked

[ Top ]
public void __destruct ( ) [line 69]

Destructor

  • postcondition:  ensures all Constraint object are deleted

[ Top ]
public void addConstraint ( Gumbo_Interface_Constraint $obj ) [line 126]

Adds a Constraint against the Data (additional arguments accepted for Constraint parameters)

Parameter(s):

  • postcondition:  !isClean()
  • postcondition:  !isChecked()
Implementation of:
Gumbo_Interface_Input::addConstraint()

[ Top ]
public void addReturnConstraint ( Gumbo_Interface_Constraint $obj ) [line 140]

Adds a return Constraint, which returns a formatted value

Parameter(s):

  • postcondition:  !isClean()
  • postcondition:  !isChecked()
Implementation of:
Gumbo_Interface_Input::addReturnConstraint()

[ Top ]
public bool clean ( ) [line 82]

Cleans the Data by running through the Constraints

  • precondition:  !isChecked()
  • throws:  Gumbo_Exception
Implementation of:
Gumbo_Interface_Input::clean()

[ Top ]
public Gumbo_Interface_Constraint[] getConstraints ( ) [line 274]

Returns ALL the Constraints

Implementation of:
Gumbo_Interface_Input::getConstraints()

[ Top ]
public mixed getData ( [bool $raw] ) [line 252]

Returns the Data

Parameter(s):

  • (bool) $raw :: as raw data
  • throws:  Gumbo_Exception
Implementation of:
Gumbo_Interface_Input::getData()

[ Top ]
public bool isChecked ( ) [line 290]

Returns if the Data was checked

Implementation of:
Gumbo_Interface_Input::isChecked()

[ Top ]
public bool isClean ( ) [line 282]

Returns if the Data is clean

Implementation of:
Gumbo_Interface_Input::isClean()

[ Top ]
public void resetConstraints ( ) [line 154]

Resets ALL Constraints

  • postcondition:  !getConstraints()
  • postcondition:  !isChecked()
  • postcondition:  !isClean()
Implementation of:
Gumbo_Interface_Input::resetConstraints()

[ Top ]
protected void setChecked ( bool $val ) [line 230]

Sets the Data as Checked

Parameter(s):

  • (bool) $val
  • throws:  Gumbo_Exception

[ Top ]
protected void setClean ( bool $val ) [line 212]

Sets the Data as Clean

Parameter(s):

  • (bool) $val
  • throws:  Gumbo_Exception

[ Top ]
protected void setCleanData ( mixed $data ) [line 185]

Sets the Clean Data

Parameter(s):

  • (mixed) $data

[ Top ]
public void setData ( mixed $data ) [line 171]

Sets the input data

Parameter(s):

  • (mixed) $data
  • postcondition:  !isClean()
  • postcondition:  !isChecked()
Implementation of:
Gumbo_Interface_Input::setData()

[ Top ]
public void setRunThru ( bool $val ) [line 194]

Sets if ALL Exceptions should be caught, or stop at first Exception

Parameter(s):

  • (bool) $val
  • throws:  Gumbo_Exception
Implementation of:
Gumbo_Interface_Input::setRunThru()

[ Top ]
public bool toRunThru ( ) [line 298]

Returns if all Exceptions should be caught, or stop at first Exception

Implementation of:
Gumbo_Interface_Input::toRunThru()

[ Top ]