public function expand(array $options = [])
    {
        if (!empty($this->href)) {
            return $this->href;
        } else if (!empty($this->{'href-template'})) {
            $parser = new UriTemplate();
            return $parser->expand($this->{'href-template'}, $this->_convertOptions($options));
        } else {
            throw new LinkException('Cannot expand link because no href or href-template defined');
        }
    }
public function expand(array $options = [])
    {
        if (!empty($this->href)) {
            return $this->href;
        } else if (!empty($this->{'href-template'})) {
            $parser = new UriTemplate();
            return $parser->expand($this->{'href-template'}, $this->_convertOptions($options));
        } else {
            throw new LinkException('Cannot expand link because no href or href-template defined');
        }
    }
public function expand ( array $ options = [ ] ) { if ( ! empty ( $ this -> href ) ) { return $ this -> href ; } else if ( ! empty ( $ this -> { 'href-template' } ) ) { $ parser = new UriTemplate ( ) ; return $ parser -> expand ( $ this -> { 'href-template' } , $ this -> _convertOptions ( $ options ) ) ; } else { throw new LinkException ( 'Cannot expand link because no href or href-template defined' ) ; } }
Resolve this link's URL from its href or href-template

@param array $options array of href-template params
@return string the resolved URL
Resolve this link s URL from its href or href - template