Skip to content

Commit

Permalink
Merge pull request #7 from koriym/init
Browse files Browse the repository at this point in the history
init() method called by @PostConstruct
  • Loading branch information
koriym committed Sep 7, 2015
2 parents 4170927 + 706672b commit 7b7f581
Showing 1 changed file with 32 additions and 0 deletions.
32 changes: 32 additions & 0 deletions src/AbstractAuraForm.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,43 @@
use Aura\Html\HelperLocator;
use Aura\Html\HelperLocatorFactory;
use Aura\Input\AntiCsrfInterface;
use Aura\Input\BuilderInterface;
use Aura\Input\FilterInterface;
use Aura\Input\Form;
use Ray\Di\Di\Inject;
use Ray\Di\Di\PostConstruct;

abstract class AbstractAuraForm extends Form implements FormInterface
{
/**
* @\Ray\Di\Di\Inject
*
* @param BuilderInterface $builder An object to build input objects.
*
* @param FilterInterface $filter A filter object for this fieldset.
*
* @param object $options An arbitrary options object for use when setting
* up inputs and filters.
*
*/
public function parentConstruct(
BuilderInterface $builder,
FilterInterface $filter,
$options = null
) {
$this->builder = $builder;
$this->filter = $filter;
$this->options = $options;
}

/**
* @PostConstruct
*/
public function postConstruct()
{
$this->init();
}

/**
* @var HelperLocator
*/
Expand Down

0 comments on commit 7b7f581

Please sign in to comment.