You are here

public function Asset::setCreatedTime in farmOS 2.x

Sets the asset creation timestamp.

Parameters

int $timestamp: Creation timestamp of the asset.

Return value

\Drupal\asset\Entity\AssetInterface The asset entity.

Overrides AssetInterface::setCreatedTime

File

modules/core/asset/src/Entity/Asset.php, line 126

Class

Asset
Defines the asset entity.

Namespace

Drupal\asset\Entity

Code

public function setCreatedTime($timestamp) {
  $this
    ->set('created', $timestamp);
  return $this;
}