for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* The common part of each element in a form
*
* @category lib
* @package lib\Form
* @author Judicaël Paquet <[email protected]>
* @copyright Copyright (c) 2013-2014 PAQUET Judicaël FR Inc. (https://github.com/las93)
* @license https://github.com/las93/venus2/blob/master/LICENSE.md Tout droit réservé à PAQUET Judicaël
* @version Release: 1.0.0
* @filesource https://github.com/las93/venus2
* @link https://github.com/las93
* @since 1.0
*/
namespace Venus\lib\Form;
abstract class Common
{
* the name of element
* @access private
* @var string
private $_sName = null;
* constraints on the element
private $_aConstraints = null;
* get the name
* @access public
* @return string
public function getName() : string
return $this->_sName;
}
* @param string $sName name;
* @return object
public function setName(string $sName)
$this->_sName = $sName;
return $this;
* get the <html>
abstract public function fetch() : string;
* set the constraint
* @param object $oConstraint constraint;
public function setConstraint($oConstraint)
$this->_aConstraints[] = $oConstraint;
* get the constraint
* @return array
public function getConstraint() : array
return $this->_aConstraints;