private function create_student($row) { $obj = new student(); $obj->setstudentId($row["student_Id"]); $obj->setFirstName($row["FirstName"]); $obj->setLastName($row["LastName"]); $obj->setDob(new \DateTime($row["dob"])); $obj->setGender($row["gender"]); $obj->setUsername($row["UserName"]); $obj->setPassword($row["password"]); $obj->setapproved($row["approved"]); return $obj; }