AgsPollingThread

AgsPollingThread — polling thread

Functions

Types and Values

Object Hierarchy

    GObject
    ╰── AgsThread
        ╰── AgsPollingThread

Implemented Interfaces

AgsPollingThread implements AgsConnectable.

Includes

#include <ags/thread/ags_polling_thread.h>

Description

The AgsPollingThread polls on the given file descriptors.

Functions

ags_polling_thread_fd_position ()

gint
ags_polling_thread_fd_position (AgsPollingThread *polling_thread,
                                int fd);

Tell position of fd within pollfd struct array.

Parameters

polling_thread

the AgsPollingThread

 

fd

file descriptor to find

 

Returns

the position if found, otherwise -1

Since: 2.0.0


ags_polling_thread_add_poll_fd ()

void
ags_polling_thread_add_poll_fd (AgsPollingThread *polling_thread,
                                GObject *gobject);

Add a gobject to AgsPollingThread.

Parameters

polling_thread

the AgsPollingThread

 

gobject

the AgsPollFd to add

 

Since: 2.0.0


ags_polling_thread_remove_poll_fd ()

void
ags_polling_thread_remove_poll_fd (AgsPollingThread *polling_thread,
                                   GObject *gobject);

ags_polling_thread_new ()

AgsPollingThread *
ags_polling_thread_new ();

Create a new AgsPollingThread.

Returns

the new AgsPollingThread

Since: 2.0.0


AGS_IS_POLLING_THREAD()

#define AGS_IS_POLLING_THREAD(obj)             (G_TYPE_CHECK_INSTANCE_TYPE ((obj), AGS_TYPE_POLLING_THREAD))

AGS_POLLING_THREAD()

#define AGS_POLLING_THREAD(obj)                (G_TYPE_CHECK_INSTANCE_CAST((obj), AGS_TYPE_POLLING_THREAD, AgsPollingThread))

AGS_POLLING_THREAD_CLASS()

#define AGS_POLLING_THREAD_CLASS(class)        (G_TYPE_CHECK_CLASS_CAST(class, AGS_TYPE_POLLING_THREAD, AgsPollingThreadClass))

AGS_POLLING_THREAD_GET_CLASS()

#define AGS_POLLING_THREAD_GET_CLASS(obj)      (G_TYPE_INSTANCE_GET_CLASS(obj, AGS_TYPE_POLLING_THREAD, AgsPollingThreadClass))

ags_polling_thread_get_type ()

GType
ags_polling_thread_get_type ();

Types and Values

AGS_POLLING_THREAD_RT_PRIORITY

#define AGS_POLLING_THREAD_RT_PRIORITY (95)

AGS_POLLING_THREAD_DEFAULT_JIFFIE

#define AGS_POLLING_THREAD_DEFAULT_JIFFIE (100.0) //NOTE:JK: take care of AGS_POLLING_THREAD_UNDERLOAD as exceeding AGS_THREAD_HERTZ_JIFFIE

AGS_POLLING_THREAD_UNDERLOAD

#define AGS_POLLING_THREAD_UNDERLOAD (4500)

enum AgsPollingThreadFlags

Enum values to control the behavior or indicate internal state of AgsPollingThread by enable/disable as flags.

Members

AGS_POLLING_THREAD_PERFORMANCE

not used

 

AGS_POLLING_THREAD_OMIT

omit poll

 

AGS_TYPE_POLLING_THREAD

#define AGS_TYPE_POLLING_THREAD                (ags_polling_thread_get_type())

struct AgsPollingThread

struct AgsPollingThread;

struct AgsPollingThreadClass

struct AgsPollingThreadClass {
  AgsThreadClass thread;
};