public function YamlFormSubmission::getData in YAML Form 8
Gets the form submission's data.
Parameters
string $key: A string that maps to a key in the submission's data. If no key is specified, then the entire data array is returned.
Return value
array The form submission data.
Overrides YamlFormSubmissionInterface::getData
1 call to YamlFormSubmission::getData()
- YamlFormSubmission::toArray in src/
Entity/ YamlFormSubmission.php - Gets an array of all property values.
File
- src/
Entity/ YamlFormSubmission.php, line 332
Class
- YamlFormSubmission
- Defines the YamlFormSubmission entity.
Namespace
Drupal\yamlform\EntityCode
public function getData($key = NULL) {
if (isset($key)) {
return isset($this->data[$key]) ? $this->data[$key] : NULL;
}
else {
return $this->data;
}
}