示例#1
0
 /**
  * @inheritdoc
  */
 public function getAuthority()
 {
     $port = '';
     if (!$this->hasStandardPort()) {
         $port = $this->port->getUriComponent();
     }
     return $this->userInfo->getUriComponent() . $this->host->getUriComponent() . $port;
 }
示例#2
0
 /**
  * Format a Host according to the Formatter properties
  *
  * @param HostInterface $host
  *
  * @return string
  */
 protected function formatHost(HostInterface $host)
 {
     if (self::HOST_AS_ASCII == $this->hostEncoding) {
         return $host->toAscii()->__toString();
     }
     return $host->toUnicode()->__toString();
 }
示例#3
0
 /**
  * {@inheritdoc}
  */
 public function filterHost(callable $callable, $flag = Interfaces\Collection::FILTER_USE_VALUE)
 {
     return $this->withProperty('host', $this->host->filter($callable, $flag));
 }