Datatypes\Boolean\Editor::load PHP 메소드

load() 공개 메소드

Load Boolean editor
public load ( ) : Zend\Form\Element\Checkbox
리턴 Zend\Form\Element\Checkbox
    public function load()
    {
        $boolean = new Element\Checkbox($this->getName());
        $boolean->setLabel($this->getProperty()->getName());
        $boolean->setAttribute('class', 'input-checkbox');
        $boolean->setAttribute('id', 'boolean' . $this->getProperty()->getId());
        $boolean->setValue($this->getProperty()->getValue());
        return $boolean;
    }

Usage Example

예제 #1
0
 /**
  * Test
  *
  * @return void
  */
 public function testLoad()
 {
     $this->assertInstanceOf('Zend\\Form\\Element\\Checkbox', $this->object->load());
 }