Documentation ¶
Index ¶
- type Collector
- func (c *Collector) BuildTagCache() error
- func (c *Collector) FetchTagsForObjects(objectsSlice interface{}) (TagsByObject, error)
- func (c *Collector) GetTagByID(id string) Tag
- func (c *Collector) GetTagsByCategories(ref mor) map[string]string
- func (c *Collector) GetTagsForObject(or mor) []Tag
- func (c *Collector) MatchObjectTags(resource mor) bool
- func (c *Collector) ParseFilterTagExpression(tagFilterExpression string)
- type Tag
- type TagsByID
- type TagsByObject
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Collector ¶
type Collector struct {
// contains filtered or unexported fields
}
func (*Collector) BuildTagCache ¶
BuildTagCache caches all tag and categories from vCenter and stores them for future reference each invocation of this func will clear any previously cached values
func (*Collector) FetchTagsForObjects ¶
func (c *Collector) FetchTagsForObjects(objectsSlice interface{}) (TagsByObject, error)
func (*Collector) GetTagByID ¶
GetTagById gets a tag by it's id
func (*Collector) GetTagsByCategories ¶
GetTagsByCategories return a map of tags categories and the corresponding tags associated to the object
func (*Collector) GetTagsForObject ¶
GetTagsForObject gets all tags for a object
func (*Collector) MatchObjectTags ¶
MatchObjectTags checks if any tag in the resource tags matches any of the 'filterTags'
func (*Collector) ParseFilterTagExpression ¶
ParseFilterTagExpression converts a filter tag expression into a slice of Tag example: tag=value tag1=value1 --> t:{c: tag, n: value}, t1:{c: tag1, n: value1} each invocation of this function resets any previously created filter