original_string: public static function getHostUri()
    {
      $sheme = (self::getHostParam("HTTPS") == "on") ? "https" : "http";
  
      $serverName = new Str(self::getHostParam("HTTP_HOST"));
      $serverPort = self::getHostParam("SERVER_PORT");
      $serverPort = ($serverPort != 80 && $serverPort != 443) ? ":" . $serverPort : "";
  
      if($serverName->endsWith($serverPort))
      {
        $serverName = $serverName->replace($serverPort, "");
      }
  
      return new Str($sheme . "://" . $serverName . $serverPort);
    }
code: public static function getHostUri()
    {
      $sheme = (self::getHostParam("HTTPS") == "on") ? "https" : "http";
  
      $serverName = new Str(self::getHostParam("HTTP_HOST"));
      $serverPort = self::getHostParam("SERVER_PORT");
      $serverPort = ($serverPort != 80 && $serverPort != 443) ? ":" . $serverPort : "";
  
      if($serverName->endsWith($serverPort))
      {
        $serverName = $serverName->replace($serverPort, "");
      }
  
      return new Str($sheme . "://" . $serverName . $serverPort);
    }
code_tokens: public static function getHostUri ( ) { $ sheme = ( self :: getHostParam ( "HTTPS" ) == "on" ) ? "https" : "http" ; $ serverName = new Str ( self :: getHostParam ( "HTTP_HOST" ) ) ; $ serverPort = self :: getHostParam ( "SERVER_PORT" ) ; $ serverPort = ( $ serverPort != 80 && $ serverPort != 443 ) ? ":" . $ serverPort : "" ; if ( $ serverName -> endsWith ( $ serverPort ) ) { $ serverName = $ serverName -> replace ( $ serverPort , "" ) ; } return new Str ( $ sheme . "://" . $ serverName . $ serverPort ) ; }
docstring: Returns the applications host address.
  
  @return Str
docstring_tokens: Returns the applications host address .