You are here

public function PatternDefinition::getFieldDefinition in UI Patterns 8

Factory method: create a new field definition.

Parameters

string $name: Field name.

string $value: Field value.

Return value

\Drupal\ui_patterns\Definition\PatternDefinitionField Definition instance.

2 calls to PatternDefinition::getFieldDefinition()
PatternDefinition::setField in src/Definition/PatternDefinition.php
Set field.
PatternDefinition::setFields in src/Definition/PatternDefinition.php
Setter.

File

src/Definition/PatternDefinition.php, line 630

Class

PatternDefinition
Class PatternDefinition.

Namespace

Drupal\ui_patterns\Definition

Code

public function getFieldDefinition($name, $value) {
  return new PatternDefinitionField($name, $value);
}