Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
Public Member Functions | Data Fields
EavAttributeInterface Interface Reference
Inheritance diagram for EavAttributeInterface:
AttributeInterface CustomAttributesDataInterface MetadataObjectInterface ExtensibleDataInterface CategoryAttributeInterface ProductAttributeInterface Attribute Attribute ProductAttributeInterface

Public Member Functions

 getIsWysiwygEnabled ()
 
 setIsWysiwygEnabled ($isWysiwygEnabled)
 
 getIsHtmlAllowedOnFront ()
 
 setIsHtmlAllowedOnFront ($isHtmlAllowedOnFront)
 
 getUsedForSortBy ()
 
 setUsedForSortBy ($usedForSortBy)
 
 getIsFilterable ()
 
 setIsFilterable ($isFilterable)
 
 getIsFilterableInSearch ()
 
 getIsUsedInGrid ()
 
 getIsVisibleInGrid ()
 
 getIsFilterableInGrid ()
 
 setIsUsedInGrid ($isUsedInGrid)
 
 setIsVisibleInGrid ($isVisibleInGrid)
 
 setIsFilterableInGrid ($isFilterableInGrid)
 
 setIsFilterableInSearch ($isFilterableInSearch)
 
 getPosition ()
 
 setPosition ($position)
 
 getApplyTo ()
 
 setApplyTo ($applyTo)
 
 getIsSearchable ()
 
 setIsSearchable ($isSearchable)
 
 getIsVisibleInAdvancedSearch ()
 
 setIsVisibleInAdvancedSearch ($isVisibleInAdvancedSearch)
 
 getIsComparable ()
 
 setIsComparable ($isComparable)
 
 getIsUsedForPromoRules ()
 
 setIsUsedForPromoRules ($isUsedForPromoRules)
 
 getIsVisibleOnFront ()
 
 setIsVisibleOnFront ($isVisibleOnFront)
 
 getUsedInProductListing ()
 
 setUsedInProductListing ($usedInProductListing)
 
 getIsVisible ()
 
 setIsVisible ($isVisible)
 
 getScope ()
 
 setScope ($scope)
 
 getExtensionAttributes ()
 
- Public Member Functions inherited from AttributeInterface
 getAttributeId ()
 
 setAttributeId ($attributeId)
 
 getAttributeCode ()
 
 setAttributeCode ($attributeCode)
 
 getFrontendInput ()
 
 setFrontendInput ($frontendInput)
 
 getEntityTypeId ()
 
 setEntityTypeId ($entityTypeId)
 
 getIsRequired ()
 
 setIsRequired ($isRequired)
 
 getOptions ()
 
 setOptions (array $options=null)
 
 getIsUserDefined ()
 
 setIsUserDefined ($isUserDefined)
 
 getDefaultFrontendLabel ()
 
 setDefaultFrontendLabel ($defaultFrontendLabel)
 
 getFrontendLabels ()
 
 setFrontendLabels (array $frontendLabels=null)
 
 getNote ()
 
 setNote ($note)
 
 getBackendType ()
 
 setBackendType ($backendType)
 
 getBackendModel ()
 
 setBackendModel ($backendModel)
 
 getSourceModel ()
 
 setSourceModel ($sourceModel)
 
 getDefaultValue ()
 
 setDefaultValue ($defaultValue)
 
 getIsUnique ()
 
 setIsUnique ($isUnique)
 
 getFrontendClass ()
 
 setFrontendClass ($frontendClass)
 
 getValidationRules ()
 
 setValidationRules (array $validationRules=null)
 
 setExtensionAttributes (\Magento\Eav\Api\Data\AttributeExtensionInterface $extensionAttributes)
 
- Public Member Functions inherited from CustomAttributesDataInterface
 getCustomAttribute ($attributeCode)
 
 setCustomAttribute ($attributeCode, $attributeValue)
 
 getCustomAttributes ()
 
 setCustomAttributes (array $attributes)
 

Data Fields

const IS_WYSIWYG_ENABLED = 'is_wysiwyg_enabled'
 
const IS_HTML_ALLOWED_ON_FRONT = 'is_html_allowed_on_front'
 
const USED_FOR_SORT_BY = 'used_for_sort_by'
 
const IS_FILTERABLE = 'is_filterable'
 
const IS_FILTERABLE_IN_SEARCH = 'is_filterable_in_search'
 
const IS_USED_IN_GRID = 'is_used_in_grid'
 
const IS_VISIBLE_IN_GRID = 'is_visible_in_grid'
 
const IS_FILTERABLE_IN_GRID = 'is_filterable_in_grid'
 
const POSITION = 'position'
 
const APPLY_TO = 'apply_to'
 
const IS_SEARCHABLE = 'is_searchable'
 
const IS_VISIBLE_IN_ADVANCED_SEARCH = 'is_visible_in_advanced_search'
 
const IS_COMPARABLE = 'is_comparable'
 
const IS_USED_FOR_PROMO_RULES = 'is_used_for_promo_rules'
 
const IS_VISIBLE_ON_FRONT = 'is_visible_on_front'
 
const USED_IN_PRODUCT_LISTING = 'used_in_product_listing'
 
const IS_VISIBLE = 'is_visible'
 
const SCOPE_STORE_TEXT = 'store'
 
const SCOPE_GLOBAL_TEXT = 'global'
 
const SCOPE_WEBSITE_TEXT = 'website'
 
- Data Fields inherited from AttributeInterface
const ATTRIBUTE_ID = 'attribute_id'
 
const IS_UNIQUE = 'is_unique'
 
const SCOPE = 'scope'
 
const FRONTEND_CLASS = 'frontend_class'
 
const ATTRIBUTE_CODE = 'attribute_code'
 
const FRONTEND_INPUT = 'frontend_input'
 
const IS_REQUIRED = 'is_required'
 
const OPTIONS = 'options'
 
const IS_USER_DEFINED = 'is_user_defined'
 
const FRONTEND_LABEL = 'frontend_label'
 
const FRONTEND_LABELS = 'frontend_labels'
 
const NOTE = 'note'
 
const BACKEND_TYPE = 'backend_type'
 
const BACKEND_MODEL = 'backend_model'
 
const SOURCE_MODEL = 'source_model'
 
const VALIDATE_RULES = 'validate_rules'
 
const ENTITY_TYPE_ID = 'entity_type_id'
 
- Data Fields inherited from CustomAttributesDataInterface
const CUSTOM_ATTRIBUTES = 'custom_attributes'
 
- Data Fields inherited from ExtensibleDataInterface
const EXTENSION_ATTRIBUTES_KEY = 'extension_attributes'
 

Detailed Description

@api

Since
100.0.2

Definition at line 13 of file EavAttributeInterface.php.

Member Function Documentation

◆ getApplyTo()

getApplyTo ( )

Get apply to value for the element

Apply to. Empty for "Apply to all" or array of the following possible values:

  • 'simple',
  • 'grouped',
  • 'configurable',
  • 'virtual',
  • 'bundle',
  • 'downloadable'
Returns
string[]|null

Implemented in Attribute, and Attribute.

◆ getExtensionAttributes()

getExtensionAttributes ( )
Returns
\Magento\Catalog\Api\Data\EavAttributeExtensionInterface|null

Implements AttributeInterface.

Implemented in ProductAttributeInterface.

◆ getIsComparable()

getIsComparable ( )

Whether the attribute can be compared on the frontend

Returns
string|null

Implemented in Attribute, and Attribute.

◆ getIsFilterable()

getIsFilterable ( )

Whether it used in layered navigation

Returns
bool|null

Implemented in Attribute, and Attribute.

◆ getIsFilterableInGrid()

getIsFilterableInGrid ( )

Whether it is filterable in catalog product grid

Returns
bool|null

Implemented in Attribute, and Attribute.

◆ getIsFilterableInSearch()

getIsFilterableInSearch ( )

Whether it is used in search results layered navigation

Returns
bool|null

Implemented in Attribute, and Attribute.

◆ getIsHtmlAllowedOnFront()

getIsHtmlAllowedOnFront ( )

Whether the HTML tags are allowed on the frontend

Returns
bool|null

Implemented in Attribute, and Attribute.

◆ getIsSearchable()

getIsSearchable ( )

Whether the attribute can be used in Quick Search

Returns
string|null

Implemented in Attribute, and Attribute.

◆ getIsUsedForPromoRules()

getIsUsedForPromoRules ( )

Whether the attribute can be used for promo rules

Returns
string|null

Implemented in Attribute, and Attribute.

◆ getIsUsedInGrid()

getIsUsedInGrid ( )

Whether it is used in catalog product grid

Returns
bool|null

Implemented in Attribute, and Attribute.

◆ getIsVisible()

getIsVisible ( )

Whether attribute is visible on frontend.

Returns
bool|null

Implemented in Attribute, and Attribute.

◆ getIsVisibleInAdvancedSearch()

getIsVisibleInAdvancedSearch ( )

Whether the attribute can be used in Advanced Search

Returns
string|null

Implemented in Attribute, and Attribute.

◆ getIsVisibleInGrid()

getIsVisibleInGrid ( )

Whether it is visible in catalog product grid

Returns
bool|null

Implemented in Attribute, and Attribute.

◆ getIsVisibleOnFront()

getIsVisibleOnFront ( )

Whether the attribute is visible on the frontend

Returns
string|null

Implemented in Attribute, and Attribute.

◆ getIsWysiwygEnabled()

getIsWysiwygEnabled ( )

Enable WYSIWYG flag

Returns
bool|null

Implemented in Attribute, and Attribute.

◆ getPosition()

getPosition ( )

Get position

Returns
int|null

Implemented in Attribute, and Attribute.

◆ getScope()

getScope ( )

Retrieve attribute scope

Returns
string|null

Implemented in Attribute, and Attribute.

◆ getUsedForSortBy()

getUsedForSortBy ( )

Whether it is used for sorting in product listing

Returns
bool|null

Implemented in Attribute, and Attribute.

◆ getUsedInProductListing()

getUsedInProductListing ( )

Whether the attribute can be used in product listing

Returns
string|null

Implemented in Attribute, and Attribute.

◆ setApplyTo()

setApplyTo (   $applyTo)

Set apply to value for the element

Parameters
string[]|string$applyTo
Returns
$this

Implemented in Attribute, and Attribute.

◆ setIsComparable()

setIsComparable (   $isComparable)

Set whether the attribute can be compared on the frontend

Parameters
string$isComparable
Returns
$this

Implemented in Attribute, and Attribute.

◆ setIsFilterable()

setIsFilterable (   $isFilterable)

Set whether it used in layered navigation

Parameters
bool$isFilterable
Returns
$this

Implemented in Attribute, and Attribute.

◆ setIsFilterableInGrid()

setIsFilterableInGrid (   $isFilterableInGrid)

Set is attribute filterable in grid

Parameters
bool | null$isFilterableInGrid
Returns
$this
Since
102.0.0

Implemented in Attribute, and Attribute.

◆ setIsFilterableInSearch()

setIsFilterableInSearch (   $isFilterableInSearch)

Set whether it is used in search results layered navigation

Parameters
bool$isFilterableInSearch
Returns
$this

Implemented in Attribute, and Attribute.

◆ setIsHtmlAllowedOnFront()

setIsHtmlAllowedOnFront (   $isHtmlAllowedOnFront)

Set whether the HTML tags are allowed on the frontend

Parameters
bool$isHtmlAllowedOnFront
Returns
$this

Implemented in Attribute, and Attribute.

◆ setIsSearchable()

setIsSearchable (   $isSearchable)

Whether the attribute can be used in Quick Search

Parameters
string$isSearchable
Returns
$this

Implemented in Attribute, and Attribute.

◆ setIsUsedForPromoRules()

setIsUsedForPromoRules (   $isUsedForPromoRules)

Set whether the attribute can be used for promo rules

Parameters
string$isUsedForPromoRules
Returns
$this

Implemented in Attribute, and Attribute.

◆ setIsUsedInGrid()

setIsUsedInGrid (   $isUsedInGrid)

Set is attribute used in grid

Parameters
bool | null$isUsedInGrid
Returns
$this
Since
102.0.0

Implemented in Attribute, and Attribute.

◆ setIsVisible()

setIsVisible (   $isVisible)

Set whether attribute is visible on frontend.

Parameters
bool$isVisible
Returns
$this

Implemented in Attribute, and Attribute.

◆ setIsVisibleInAdvancedSearch()

setIsVisibleInAdvancedSearch (   $isVisibleInAdvancedSearch)

Set whether the attribute can be used in Advanced Search

Parameters
string$isVisibleInAdvancedSearch
Returns
$this

Implemented in Attribute, and Attribute.

◆ setIsVisibleInGrid()

setIsVisibleInGrid (   $isVisibleInGrid)

Set is attribute visible in grid

Parameters
bool | null$isVisibleInGrid
Returns
$this
Since
102.0.0

Implemented in Attribute, and Attribute.

◆ setIsVisibleOnFront()

setIsVisibleOnFront (   $isVisibleOnFront)

Set whether the attribute is visible on the frontend

Parameters
string$isVisibleOnFront
Returns
$this

Implemented in Attribute, and Attribute.

◆ setIsWysiwygEnabled()

setIsWysiwygEnabled (   $isWysiwygEnabled)

Set whether WYSIWYG is enabled flag

Parameters
bool$isWysiwygEnabled
Returns
$this

Implemented in Attribute, and Attribute.

◆ setPosition()

setPosition (   $position)

Set position

Parameters
int$position
Returns
$this

Implemented in Attribute, and Attribute.

◆ setScope()

setScope (   $scope)

Set attribute scope

Parameters
string$scope
Returns
$this

Implemented in Attribute, and Attribute.

◆ setUsedForSortBy()

setUsedForSortBy (   $usedForSortBy)

Set whether it is used for sorting in product listing

Parameters
bool$usedForSortBy
Returns
$this

Implemented in Attribute, and Attribute.

◆ setUsedInProductListing()

setUsedInProductListing (   $usedInProductListing)

Set whether the attribute can be used in product listing

Parameters
string$usedInProductListing
Returns
$this

Implemented in Attribute, and Attribute.

Field Documentation

◆ APPLY_TO

const APPLY_TO = 'apply_to'

Definition at line 33 of file EavAttributeInterface.php.

◆ IS_COMPARABLE

const IS_COMPARABLE = 'is_comparable'

Definition at line 39 of file EavAttributeInterface.php.

◆ IS_FILTERABLE

const IS_FILTERABLE = 'is_filterable'

Definition at line 21 of file EavAttributeInterface.php.

◆ IS_FILTERABLE_IN_GRID

const IS_FILTERABLE_IN_GRID = 'is_filterable_in_grid'

Definition at line 29 of file EavAttributeInterface.php.

◆ IS_FILTERABLE_IN_SEARCH

const IS_FILTERABLE_IN_SEARCH = 'is_filterable_in_search'

Definition at line 23 of file EavAttributeInterface.php.

◆ IS_HTML_ALLOWED_ON_FRONT

const IS_HTML_ALLOWED_ON_FRONT = 'is_html_allowed_on_front'

Definition at line 17 of file EavAttributeInterface.php.

◆ IS_SEARCHABLE

const IS_SEARCHABLE = 'is_searchable'

Definition at line 35 of file EavAttributeInterface.php.

◆ IS_USED_FOR_PROMO_RULES

const IS_USED_FOR_PROMO_RULES = 'is_used_for_promo_rules'

Definition at line 41 of file EavAttributeInterface.php.

◆ IS_USED_IN_GRID

const IS_USED_IN_GRID = 'is_used_in_grid'

Definition at line 25 of file EavAttributeInterface.php.

◆ IS_VISIBLE

const IS_VISIBLE = 'is_visible'

Definition at line 47 of file EavAttributeInterface.php.

◆ IS_VISIBLE_IN_ADVANCED_SEARCH

const IS_VISIBLE_IN_ADVANCED_SEARCH = 'is_visible_in_advanced_search'

Definition at line 37 of file EavAttributeInterface.php.

◆ IS_VISIBLE_IN_GRID

const IS_VISIBLE_IN_GRID = 'is_visible_in_grid'

Definition at line 27 of file EavAttributeInterface.php.

◆ IS_VISIBLE_ON_FRONT

const IS_VISIBLE_ON_FRONT = 'is_visible_on_front'

Definition at line 43 of file EavAttributeInterface.php.

◆ IS_WYSIWYG_ENABLED

const IS_WYSIWYG_ENABLED = 'is_wysiwyg_enabled'

Definition at line 15 of file EavAttributeInterface.php.

◆ POSITION

const POSITION = 'position'

Definition at line 31 of file EavAttributeInterface.php.

◆ SCOPE_GLOBAL_TEXT

const SCOPE_GLOBAL_TEXT = 'global'

Definition at line 51 of file EavAttributeInterface.php.

◆ SCOPE_STORE_TEXT

const SCOPE_STORE_TEXT = 'store'

Definition at line 49 of file EavAttributeInterface.php.

◆ SCOPE_WEBSITE_TEXT

const SCOPE_WEBSITE_TEXT = 'website'

Definition at line 53 of file EavAttributeInterface.php.

◆ USED_FOR_SORT_BY

const USED_FOR_SORT_BY = 'used_for_sort_by'

Definition at line 19 of file EavAttributeInterface.php.

◆ USED_IN_PRODUCT_LISTING

const USED_IN_PRODUCT_LISTING = 'used_in_product_listing'

Definition at line 45 of file EavAttributeInterface.php.


The documentation for this interface was generated from the following file: