5 * Copyright 2018 Andy Street <andy@street.me.uk>
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2 of the License, or
10 * (at your option) any later version.
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
28 * A link to an external resource (Web page, digital photo, video clip, etc)
29 * with additional information.
31 * @see https://www.topografix.com/GPX/1/1/#type_linkType
33 * @author Andy Street <andy@street.me.uk>
53 * Mime type of content (image/jpeg).
62 * @param string $href The URL of the link.
64 public function __construct(string $href)
66 $this->setHref($href);
70 * Fetch the URL of the link.
74 public function getHref()
80 * Set the URL of the link.
82 * @param string $href The URL of the link.
85 public function setHref(string $href)
91 * Fetch the text of the hyperlink.
93 * @return string|null The text or null if not set.
95 public function getText()
101 * Set the text of the hyperlink.
103 * @param string|null $text The text of the link or null to delete.
106 public function setText(string $text = null)
112 * Fetch the mime type of the hyperlink.
114 * @return string|null The mime type or null if not set.
116 public function getType()
122 * Set the mime type of the hyperlink.
124 * @param string|null $type The mime type of the link or null to delete.
127 public function setType(string $type = null)