AllIds return all known bug ids
()
| 334 | |
| 335 | // AllIds return all known bug ids |
| 336 | func (sc *SubCache[EntityT, ExcerptT, CacheT]) AllIds() []entity.Id { |
| 337 | sc.mu.RLock() |
| 338 | defer sc.mu.RUnlock() |
| 339 | |
| 340 | result := make([]entity.Id, len(sc.excerpts)) |
| 341 | |
| 342 | i := 0 |
| 343 | for _, excerpt := range sc.excerpts { |
| 344 | result[i] = excerpt.Id() |
| 345 | i++ |
| 346 | } |
| 347 | |
| 348 | return result |
| 349 | } |
| 350 | |
| 351 | // Resolve retrieve an entity matching the exact given id |
| 352 | func (sc *SubCache[EntityT, ExcerptT, CacheT]) Resolve(id entity.Id) (CacheT, error) { |