(stack []*SelectedPodContainer, k string)
| 204 | } |
| 205 | |
| 206 | func contains(stack []*SelectedPodContainer, k string) bool { |
| 207 | for _, s := range stack { |
| 208 | if key(s.Pod.Namespace, s.Pod.Name, s.Container.Name) == k { |
| 209 | return true |
| 210 | } |
| 211 | } |
| 212 | return false |
| 213 | } |
| 214 | |
| 215 | func key(namespace string, pod string, container string) string { |
| 216 | return namespace + "/" + pod + "/" + container |