You are here

public function Domain::addProperty in Domain Access 8

Adds a property to the domain record.

Parameters

string $name: The name of the property to retrieve.

mixed $value: The value of the property.

Overrides DomainInterface::addProperty

File

domain/src/Entity/Domain.php, line 188

Class

Domain
Defines the domain entity.

Namespace

Drupal\domain\Entity

Code

public function addProperty($name, $value) {
  if (!isset($this->{$name})) {
    $this->{$name} = $value;
  }
}