protected function set_url($url) {
        if ($url instanceof \moodle_url) {
            $url = $url->out(false);
        }
        $this->raw_set('url', $url);
    }
protected function set_url($url) {
        if ($url instanceof \moodle_url) {
            $url = $url->out(false);
        }
        $this->raw_set('url', $url);
    }
protected function set_url ( $ url ) { if ( $ url instanceof \ moodle_url ) { $ url = $ url -> out ( false ) ; } $ this -> raw_set ( 'url' , $ url ) ; }
Convenience method handling moodle_urls.

@param null|string|moodle_url $url The URL.
Convenience method handling moodle_urls .