Log in
Model

Converter

Magento\Catalog\Model\Product\Option\Converter

What it does

This converter class transforms product custom option objects into array format.

Developers use this when they need to serialize product options (like dropdown choices, text fields, or file uploads) for storage, API responses, or data transfer between different parts of the system.

It handles both the main option data and any associated option values.

Public Methods

  • toArray()