monitor

package
v0.1.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 28, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Rendered for windows/amd64

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Monitor

type Monitor struct {
	// contains filtered or unexported fields
}

Monitor is a generic monitor to subscribe to Wmi Events based on a Query String

func CreateMonitor

func CreateMonitor(wmiNamespace string, callbackContext interface{},
	callback func(interface{}, string)) *Monitor

CreateMonitor createa a new Monitor

func (*Monitor) AddEntityWithFilter

func (c *Monitor) AddEntityWithFilter(entityName, wqlQueryString string, filters query.WmiQueryFilterCollection) (err error)

AddEntityWithFilter would add the entity to be monitored for changes

func (*Monitor) Close

func (c *Monitor) Close() error

Close the monitor

func (*Monitor) RemoveEntity

func (c *Monitor) RemoveEntity(entityName string) (err error)

RemoveEntity to remove the entity being monitored for changes

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL