newIDGenerator ensures that new ids are only created the first time they are encountered.
(seed int64)
| 208 | |
| 209 | // newIDGenerator ensures that new ids are only created the first time they are encountered. |
| 210 | func newIDGenerator(seed int64) *idGenerator { |
| 211 | return &idGenerator{ |
| 212 | idMap: make(map[int64]int64), |
| 213 | seed: seed, |
| 214 | } |
| 215 | } |
| 216 | |
| 217 | type idGenerator struct { |
| 218 | idMap map[int64]int64 |