Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GVKAgreggator ¶
type GVKAgreggator struct {
// contains filtered or unexported fields
}
GVKAgreggator is an implementation of a bi directional map that stores associations between Key K and GVKs and reverse associations between GVK g and Keys.
func NewGVKAggregator ¶
func NewGVKAggregator() *GVKAgreggator
func (*GVKAgreggator) GVKs ¶
func (b *GVKAgreggator) GVKs() []schema.GroupVersionKind
GVKs returns a list of all of the schema.GroupVersionKind that are aggregated.
func (*GVKAgreggator) IsPresent ¶
func (b *GVKAgreggator) IsPresent(gvk schema.GroupVersionKind) bool
IsPresent returns true if the given gvk is present in the GVKAggregator.
func (*GVKAgreggator) List ¶
func (b *GVKAgreggator) List(k Key) []schema.GroupVersionKind
List returnes the gvk set for a given Key.
func (*GVKAgreggator) Remove ¶
func (b *GVKAgreggator) Remove(k Key)
Remove deletes any associations that Key k has in the GVKAggregator. For any GVK in the association k --> [GVKs], we also delete any associations between the GVK and the Key k stored in the reverse map.
func (*GVKAgreggator) Upsert ¶
func (b *GVKAgreggator) Upsert(k Key, gvks []schema.GroupVersionKind)
Upsert stores an association between Key k and the list of GVKs and also the reverse association between each GVK passed in and Key k. Any old associations are dropped, unless they are included in the new list of GVKs.