You are here

public function ProfileInterface::populateFromProfile in Profile 8

Populates the profile with field values from the other profile.

Parameters

\Drupal\profile\Entity\ProfileInterface $profile: The other profile.

string[] $field_names: The names of fields to transfer. If empty, all configurable fields will be transferred.

Return value

$this

1 method overrides ProfileInterface::populateFromProfile()
Profile::populateFromProfile in src/Entity/Profile.php
Populates the profile with field values from the other profile.

File

src/Entity/ProfileInterface.php, line 169

Class

ProfileInterface
Provides an interface for profiles.

Namespace

Drupal\profile\Entity

Code

public function populateFromProfile(ProfileInterface $profile, array $field_names = []);