darwin

package
v1.0.30 Latest Latest
Warning

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

Go to latest
Published: Sep 27, 2019 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Rendered for darwin/amd64

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FlushEventStream

func FlushEventStream(stream FSEventStream, sync bool)

func ReleaseEventStream

func ReleaseEventStream(stream FSEventStream)

func RunLoopInCurrentThread

func RunLoopInCurrentThread(stop <-chan struct{}) error

func SetEventCallback

func SetEventCallback(userInfo uintptr, callback FSCallback)

func StartEventStreamInRunloop

func StartEventStreamInRunloop(stream FSEventStream, runloop CFRunLoop) bool

func StopEventStreamInRunLoop

func StopEventStreamInRunLoop(stream FSEventStream, runloop CFRunLoop)

Types

type CFArray

type CFArray C.CFMutableArrayRef

func NewCFArray

func NewCFArray(capacity uint) CFArray

func (CFArray) Append

func (this CFArray) Append(element CFType)

func (CFArray) AtIndex

func (this CFArray) AtIndex(i uint) CFType

func (CFArray) Free

func (this CFArray) Free()

func (CFArray) Len

func (this CFArray) Len() uint

type CFRunLoop

type CFRunLoop C.CFRunLoopRef

func CurrentRunLoop

func CurrentRunLoop() CFRunLoop

type CFString

type CFString C.CFStringRef

func NewCFString

func NewCFString(value string) CFString

func (CFString) Free

func (this CFString) Free()

func (CFString) String

func (this CFString) String() string

type CFType

type CFType C.CFTypeRef

type FSCallback

type FSCallback func(*FSEvent)

type FSEvent

type FSEvent struct {
	Stream   FSEventStream
	UserInfo uintptr
	Path     string
	Flags    FSEventStreamFlag
	Event    FSEventID
}

type FSEventID

type FSEventID C.FSEventStreamEventId

func LatestEventID

func LatestEventID() FSEventID

type FSEventStream

type FSEventStream C.FSEventStreamRef

func NewEventStream

func NewEventStream(paths []string, userInfo uintptr, since FSEventID, latency time.Duration, flags FSEventStreamCreateFlag) (FSEventStream, error)

type FSEventStreamContext

type FSEventStreamContext C.FSEventStreamContext

type FSEventStreamCreateFlag

type FSEventStreamCreateFlag C.uint32
const (
	FS_STREAM_CREATE_FLAG_USECFTYPES FSEventStreamCreateFlag = 1 << iota
	FS_STREAM_CREATE_FLAG_NODEFER    FSEventStreamCreateFlag = 1 << iota
	FS_STREAM_CREATE_FLAG_WATCHROOT  FSEventStreamCreateFlag = 1 << iota
	FS_STREAM_CREATE_FLAG_IGNORESELF FSEventStreamCreateFlag = 1 << iota
	FS_STREAM_CREATE_FLAG_FILEEVENTS FSEventStreamCreateFlag = 1 << iota
	FS_STREAM_CREATE_FLAG_NONE       FSEventStreamCreateFlag = 0
)

type FSEventStreamFlag

type FSEventStreamFlag C.uint32
const (
	FS_STREAM_FLAG_MUSTSCANSUBDIRS    FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_USERDROPPED        FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_KERNELDROPPED      FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_EVENTIDSWRAPPED    FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_HISTORYDONE        FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_ROOTCHANGED        FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_MOUNT              FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_UNMOUNT            FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_ITEM_CREATED       FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_ITEM_REMOVED       FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_ITEM_INODEMETAMOD  FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_ITEM_RENAMED       FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_ITEM_MODIFIED      FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_ITEM_FINDERINFOMOD FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_ITEM_CHANGEOWNER   FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_ITEM_XATTRMOD      FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_ITEM_ISFILE        FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_ITEM_ISDIR         FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_ITEM_ISSYMLINK     FSEventStreamFlag = 1 << iota
	FS_STREAM_FLAG_MIN                                  = FS_STREAM_FLAG_MUSTSCANSUBDIRS
	FS_STREAM_FLAG_MAX                                  = FS_STREAM_FLAG_ITEM_ISSYMLINK
	FS_STREAM_FLAG_NONE               FSEventStreamFlag = 0
)

func (FSEventStreamFlag) String

func (f FSEventStreamFlag) String() string

Jump to

Keyboard shortcuts

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