1
0
mirror of https://github.com/chai2010/advanced-go-programming-book.git synced 2025-05-24 12:32:21 +00:00

Update ch5-02-router.md

This commit is contained in:
LaoK996 2018-11-23 19:46:08 +08:00 committed by GitHub
parent 57d110b19e
commit 16c4ea82e1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -231,4 +231,4 @@ indices: 子节点索引,当子节点为非参数类型,即本节点的 wild
4. 在插入 static 节点时,父节点的 wildChild 字段被设置为 true。 4. 在插入 static 节点时,父节点的 wildChild 字段被设置为 true。
5. 在插入 static 节点时,父节点的 children 非空,且子节点 nType 为 catchAll。 5. 在插入 static 节点时,父节点的 children 非空,且子节点 nType 为 catchAll。
只要发生冲突,都会在初始化的时候 panic。例如在插入我们臆想的路由`GET /marketplace_listing/plans/ohyes`出现第4种冲突情况它的父节点`marketplace_listing/plans/`的 wildChild 字段为true。 只要发生冲突,都会在初始化的时候 panic。例如在插入我们臆想的路由`GET /marketplace_listing/plans/ohyes`出现第4种冲突情况它的父节点`marketplace_listing/plans/`的 wildChild 字段为 true。