UrlBuilder
链式风格的URL生成器,简单、直观、易用、安全。
Introduce
下图显示了两个示例URI及其组成部分:
hierarchical part
┌─────────────────────────────────┴───────────────────────────────────┐
authority path
┌───────────────────────────┴───────────────────────┐┌───────┴────────┐
abc://username:password@example.com:123/path/data?key=value&key2=value2#fragid1
└┬┘ └─────────────┬─────────────┘ └────┬────┘ └─────────┬─────────┘ └───────┬──────┘ └──┬──┘
scheme user-information host port query fragment
urn:example:mammal:monotreme:echidna
└┬┘ └────────────────────────┬─────