function Course::set_degree_details_from_data_array

7.x Course.php Course::set_degree_details_from_data_array($arr, $property_name)
6.x Course.php Course::set_degree_details_from_data_array($arr, $property_name)

This is the reverse function of:

See also

get_degree_details_data_string

1 call to Course::set_degree_details_from_data_array()
Course::load_course_from_data_string in classes/Course.php
This will take a data string, as created by the function to_data_string(), and make $this object match the original object. It is a poor man's unserialize. See to_data_string()'s description for a fuller picture of what is going on.

File

classes/Course.php, line 668

Class

Course

Code

function set_degree_details_from_data_array($arr, $property_name) {
  foreach ($arr as $degree_id => $val) {
    $this->details_by_degree_array [$degree_id][$property_name] = $val;
  }
}