public function popField()
    {
        if ($this->getCount() > 0) {
            $fields = $this->removeFieldAtIndex($this->getCount() - 1);
            return $fields[0];
        }

        throw new \OutOfRangeException("Can't call popField when the field count is 0");
    }
public function popField()
    {
        if ($this->getCount() > 0) {
            $fields = $this->removeFieldAtIndex($this->getCount() - 1);
            return $fields[0];
        }

        throw new \OutOfRangeException("Can't call popField when the field count is 0");
    }
public function popField ( ) { if ( $ this -> getCount ( ) > 0 ) { $ fields = $ this -> removeFieldAtIndex ( $ this -> getCount ( ) - 1 ) ; return $ fields [ 0 ] ; } throw new \ OutOfRangeException ( "Can't call popField when the field count is 0" ) ; }
Remove last field from end of array
@throws \OutOfRangeException if array is empty
@return NamedBuilder Field array config or Builder
Remove last field from end of array