private function getMultiFieldMappingPropertyConfig($analyzers)
{
// Setting the field type to "multi_field".
$property = ['type' => self::FIELD_TYPE_MULTI];
foreach ($analyzers as $analyzer) {
// Using the analyzer name as subfield name by default.
$subFieldName = $analyzer;
if ($analyzer == self::ANALYZER_STANDARD && $this->isNested()) {
// Using the field suffix as default subfield name for nested fields.
$subFieldName = $this->getNestedFieldName();
} elseif ($analyzer == self::ANALYZER_STANDARD) {
// Using the field name as default subfield name for normal fields.
$subFieldName = $this->getName();
}
$property['fields'][$subFieldName] = $this->getPropertyConfig($analyzer);
}
return $property;
}