package Default

 Methods

Can we create the requested service?

canCreateServiceWithName(\Zend\ServiceManager\ServiceLocatorInterface $serviceLocator, string $name, string $requestedName) : boolean
inherited_from \Zend\ServiceManager\AbstractFactoryInterface::canCreateServiceWithName()

Parameters

$serviceLocator

\Zend\ServiceManager\ServiceLocatorInterface

$name

string

Service name (as resolved by ServiceManager)

$requestedName

string

Name by which service was requested

Returns

boolean

Create a form

createServiceWithName(\Zend\ServiceManager\ServiceLocatorInterface $serviceLocator, string $name, string $requestedName) : \Zend\Form\Form
inherited_from \Zend\ServiceManager\AbstractFactoryInterface::createServiceWithName()

Parameters

$serviceLocator

\Zend\ServiceManager\ServiceLocatorInterface

$name

string

Service name (as resolved by ServiceManager)

$requestedName

string

Name by which service was requested

Returns

\Zend\Form\Form

Get forms configuration, if any

getConfig(\Zend\ServiceManager\ServiceLocatorInterface $services) : array

Parameters

$services

\Zend\ServiceManager\ServiceLocatorInterface

Returns

array

Retrieve the form factory, creating it if necessary

getFormFactory(\Zend\ServiceManager\ServiceLocatorInterface $services) : \Zend\Form\Factory

Parameters

$services

\Zend\ServiceManager\ServiceLocatorInterface

Returns

\Zend\Form\Factory

Marshal the input filter into the configuration

marshalInputFilter(array $config, \Zend\ServiceManager\ServiceLocatorInterface $services, \Zend\Form\Factory $formFactory) 

If an input filter is specified:

  • if the InputFilterManager is present, checks if it's there; if so, retrieves it and resets the specification to the instance.
  • otherwise, pulls the input filter factory from the form factory, and attaches the FilterManager and ValidatorManager to it.

Parameters

$config

array

$services

\Zend\ServiceManager\ServiceLocatorInterface

$formFactory

\Zend\Form\Factory

 Properties

 

$config

$config : array

Default

 

Top-level configuration key indicating forms configuration

$configKey : string

Default

'forms'
 

Form factory used to create forms

$factory : \Zend\Form\Factory

Default