Smile\ElasticsuiteCatalog\Helper\Attribute::getAttributeId PHP Method

getAttributeId() private method

This util method is used to ensure the attribute is an integer and uses it's id if it is an object.
private getAttributeId ( Magento\Eav\Model\Entity\Attribute\AttributeInterface | integer $attribute ) : integer
$attribute Magento\Eav\Model\Entity\Attribute\AttributeInterface | integer Product attribute.
return integer
    private function getAttributeId($attribute)
    {
        $attributeId = $attribute;
        if (is_object($attribute)) {
            $attributeId = $attribute->getAttributeId();
        }
        return $attributeId;
    }