You are here

public function ProductVariation::setTitle in Commerce Core 8.2

Sets the variation title.

Parameters

string $title: The variation title.

Return value

$this

Overrides ProductVariationInterface::setTitle

1 call to ProductVariation::setTitle()
ProductVariation::preSave in modules/product/src/Entity/ProductVariation.php
Acts on an entity before the presave hook is invoked.

File

modules/product/src/Entity/ProductVariation.php, line 181

Class

ProductVariation
Defines the product variation entity class.

Namespace

Drupal\commerce_product\Entity

Code

public function setTitle($title) {
  $this
    ->set('title', $title);
  return $this;
}