Bases: object
Adds a callback for activity on the given file descriptor.
func will be called during the execution of main_loop_begin() when the file descriptor is available for reading, or writing, or both.
When the handler func is called, it must return a value of either True or False (remember that Python returns None if no value is explicitly returned and None evaluates to False). If it returns True, it will continue to monitor the given file descriptor, or if it returns False it will be deleted automatically making any references/handles for it invalid.
FdHandler use includes:
Parameters: |
|
---|
Expected func signature:
func(fd_handler, *args, **kargs): bool
Return if read, write or error, or a combination thereof, is active on the file descriptor of the given FD handler.
Return type: | bool |
---|
Set what active streams the given FdHandler should be monitoring.
Parameters: | flags – one of - ECORE_FD_NONE - ECORE_FD_READ - ECORE_FD_WRITE - ECORE_FD_ERROR - ECORE_FD_ALL |
---|
Return type: | bool |
---|
Return type: | bool |
---|
Stop callback emission and free internal resources.
Get the file descriptor number
Return type: | int |
---|
Return type: | bool |
---|
Set a function to call before doing the select() on the fd.
Expected signature:
function(object, *args, **kargs)
Alias for delete.