public function get_my_dependency_properties($settingname=null) {
        if ($settingname ==  null) {
            $settingname = $this->get_ui_name();
        }
        $dependencies = array();
        foreach ($this->dependenton as $dependenton) {
            $properties = $dependenton->get_moodleform_properties();
            $properties['setting'] = $settingname;
            $dependencies[$properties['setting'].'-'.$properties['dependenton']] = $properties;
            $dependencies = array_merge($dependencies, $dependenton->get_setting()->get_my_dependency_properties($settingname));
        }
        return $dependencies;
    }