2015-08-12 06:08:32 +02:00
|
|
|
<?php
|
|
|
|
|
2017-08-09 01:55:09 +02:00
|
|
|
namespace SilverStripe\UserForms\FormField;
|
|
|
|
|
2017-08-11 02:36:28 +02:00
|
|
|
use SilverStripe\UserForms\Model\EditableFormField;
|
2017-08-09 01:55:09 +02:00
|
|
|
|
2015-08-12 06:08:32 +02:00
|
|
|
/**
|
|
|
|
* Represents a field container which can iteratively process nested fields, converting it into a fieldset
|
|
|
|
*/
|
2016-07-21 07:53:59 +02:00
|
|
|
interface UserFormsFieldContainer
|
|
|
|
{
|
2015-08-12 06:08:32 +02:00
|
|
|
|
2016-07-21 07:53:59 +02:00
|
|
|
/**
|
|
|
|
* Process the next field in the list, returning the container to add the next field to.
|
|
|
|
*
|
|
|
|
* @param EditableFormField $field
|
|
|
|
* @return EditableContainerField
|
|
|
|
*/
|
|
|
|
public function processNext(EditableFormField $field);
|
2015-08-12 06:08:32 +02:00
|
|
|
|
2016-07-21 07:53:59 +02:00
|
|
|
/**
|
|
|
|
* Set the parent
|
|
|
|
*
|
|
|
|
* @param UserFormsFieldContainer $parent
|
|
|
|
* @return $this
|
|
|
|
*/
|
|
|
|
public function setParent(UserFormsFieldContainer $parent);
|
2015-08-12 06:08:32 +02:00
|
|
|
|
2016-07-21 07:53:59 +02:00
|
|
|
/**
|
|
|
|
* Get the parent
|
|
|
|
*
|
|
|
|
* @return UserFormsFieldContainer
|
|
|
|
*/
|
|
|
|
public function getParent();
|
2015-08-12 06:08:32 +02:00
|
|
|
}
|