Magento Extensions Rating 2024
EXTENSIONS BY CATEGORY
B2B (Business-To-Business)
Blog
Customer
ERP (Enterprise Resource Planning)
Mega Menu
One Step Checkout
Order
POS (Point Of Sale)
Search
Shopping Cart
Sitemap
SEO
Social
Stock & Inventory Management
EXTENSIONS BY DEVELOPER
aheadWorks
Amasty
Boost My Shop
BSS Commerce
Magestore
MageWorx
Mirasvit
Templates Master
Wyomind
XTENTO
Magento 2 Documentation
Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
vendor
magento
module-elasticsearch
Model
Adapter
FieldMapper
Product
FieldProvider
FieldName
Resolver
SpecialAttribute.php
Go to the documentation of this file.
1
<?php
6
declare(strict_types=1);
7
8
namespace
Magento\Elasticsearch\Model\Adapter\FieldMapper\Product\FieldProvider\FieldName\Resolver
;
9
10
use
Magento\Elasticsearch\Model\Adapter\FieldMapper\Product\AttributeAdapter
;
11
use
Magento\Elasticsearch\Model\Adapter\FieldMapper\Product\FieldProvider\FieldName\ResolverInterface
;
12
16
class
SpecialAttribute
implements
ResolverInterface
17
{
25
public
function
getFieldName
(
AttributeAdapter
$attribute
, $context = []): ?string
26
{
27
if
(in_array(
$attribute
->getAttributeCode(), [
'id'
,
'sku'
,
'store_id'
,
'visibility'
],
true
)) {
28
return
$attribute
->getAttributeCode();
29
}
30
31
return
null
;
32
}
33
}
Magento\Elasticsearch\Model\Adapter\FieldMapper\Product\FieldProvider\FieldName\ResolverInterface
Definition:
ResolverInterface.php:15
Magento\Elasticsearch\Model\Adapter\FieldMapper\Product\FieldProvider\FieldName\Resolver\SpecialAttribute
Definition:
SpecialAttribute.php:16
$attribute
$attribute
Definition:
attribute_set_with_image_attribute.php:41
Magento\Elasticsearch\Model\Adapter\FieldMapper\Product\FieldProvider\FieldName\Resolver
Definition:
CategoryName.php:8
Magento\Elasticsearch\Model\Adapter\FieldMapper\Product\AttributeAdapter
Definition:
AttributeAdapter.php:15
Magento\Elasticsearch\Model\Adapter\FieldMapper\Product\FieldProvider\FieldName\Resolver\SpecialAttribute\getFieldName
getFieldName(AttributeAdapter $attribute, $context=[])
Definition:
SpecialAttribute.php:25
Magento\Elasticsearch\Model\Adapter\FieldMapper\Product\AttributeAdapter
Definition:
DummyAttribute.php:8