'attribute_date', DECIMAL => 'attribute_decimal', ]; return $columnMap[$input] ?? 'attribute_value'; } /** * Validates that the provided data type is an allowed attribute value type. * * @param string $dataType * @return void */ function validateAttributeValueType(string $dataType): void { $attributeValueTypes = ['attribute_value', 'attribute_decimal', 'attribute_date']; if (!in_array($dataType, $attributeValueTypes, true)) { throw new InvalidArgumentException('Invalid data type'); } }