【问题标题】:What is the correct terminology for breaking up a URI into its component parts?将 URI 分解为其组成部分的正确术语是什么?
【发布时间】:2011-04-05 04:15:03
【问题描述】:

假设我们有一个字符串"http://www.example.com/feed"。我将这个字符串分成三部分,以便与 Apache 的 URI 类一起使用: 1.“http” 2. “www.example.com” 3.“/饲料”

对于将 URI 分解为其组成部分的过程是否有适当的术语?

【问题讨论】:

    标签: http url uri httpclient


    【解决方案1】:

    一个 uri 可以被解析成它的组成部分:

    以下是 RFC3986 中的两个示例:

         foo://example.com:8042/over/there?name=ferret#nose
         \_/   \______________/\_________/ \_________/ \__/
          |           |            |            |        |
       scheme     authority       path        query   fragment
          |   _____________________|__
         / \ /                        \
         urn:example:animal:ferret:nose
    

    uri 可以是 url 或 urn。

    【讨论】:

      【解决方案2】:

      拆分还是解析?我认为这确实是语义上的,并且没有达成一致的术语。

      【讨论】:

        【解决方案3】:

        我总是使用术语解析。

        【讨论】:

          猜你喜欢
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 2019-01-17
          • 1970-01-01
          • 1970-01-01
          • 2011-06-23
          • 2012-04-08
          • 1970-01-01
          相关资源
          最近更新 更多