LQL Reference Manual |
---|
LQLClass — LQLClass is the base class for all QoS classes.
struct LQLClass; LQLClass* lql_class_new (void); gboolean lql_class_add (LQLClass *self, LQLCon *con); gboolean lql_class_modify (LQLClass *self, LQLCon *con); gboolean lql_class_delete (LQLClass *self, LQLCon *con); void lql_class_print (LQLClass *self); gboolean lql_class_updateStats (LQLClass *self, LQLCon *con); void lql_class_printStats (LQLClass *self); guint16 lql_class_get_id (LQLClass *self); gboolean lql_class_set_id (LQLClass *self, guint16 id); gboolean lql_class_set_parent (LQLClass *self, LQLElement *element); unsigned int lql_class_get_priority (LQLClass *self); gboolean lql_class_set_priority (LQLClass *self, unsigned int priority); gboolean lql_class_fill_from_nlhdr (LQLClass *self, const struct nlmsghdr *hdr); guint32 lql_class_get_queueLength (LQLClass *self); guint32 lql_class_get_backlog (LQLClass *self); guint32 lql_class_get_pps (LQLClass *self); guint64 lql_class_get_bytes (LQLClass *self); guint32 lql_class_get_packets (LQLClass *self); guint32 lql_class_get_overlimits (LQLClass *self); guint32 lql_class_get_bps (LQLClass *self); guint32 lql_class_get_drops (LQLClass *self);
GObject +----LQLElement +----LQLClass +----LQLClassHTB +----LQLClassPriomap +----LQLClassDSMark +----LQLClassNetem
"backlog" guint : Read "bps" guint : Read "dropped-packets" guint : Read "enqueued-bytes" gint64 : Read "enqueued-packets" guint : Read "id" guint : Read / Write "overlimits" guint : Read "pps" guint : Read "priority" guint : Read / Write "queue-length" guint : Read
LQLClass is the base class for all QoS classes. You will almost certainly never have any reason to instantiate a LQLClass instance. Always use one of the subclasses.
LQLClass* lql_class_new (void);
Build a new instance of LQLClass.
Returns : | A new LQLClass instance. |
gboolean lql_class_add (LQLClass *self, LQLCon *con);
Add this queueing discipline to the system.
self : | The LQLClass object to add to the system. |
con : | The LQLCon connection to use when adding this queueing discipline. |
Returns : | TRUE on success, FALSE on failure. |
gboolean lql_class_modify (LQLClass *self, LQLCon *con);
Modify the queueing discipline in the system to match the current object state.
self : | The LQLClass object to modify. |
con : | The LQLCon connection to use when adding this class. |
Returns : | TRUE on success, FALSE on failure. |
gboolean lql_class_delete (LQLClass *self, LQLCon *con);
Delete this queueing discipline from the system.
self : | The LQLClass object to delete from the system. |
con : | The LQLCon connection to use when deleting this queueing discipline. |
Returns : | TRUE on success, FALSE on failure. |
void lql_class_print (LQLClass *self);
Print out the parameters for this class. Each sub-class overrides this method to print out class specific details.
self : | The LQLClass instance. |
gboolean lql_class_updateStats (LQLClass *self, LQLCon *con);
This method is used to communicate with the kernel to get updated statistics information for this class.
self : | The LQLClass instance. |
con : | The LQLCon instance. |
Returns : | TRUE on success, FALSE on failure. |
void lql_class_printStats (LQLClass *self);
Print out the statistics information for this class. Each sub-class of LQLClass overrides this method to print out class specific details.
self : | The LQLClass instance. |
guint16 lql_class_get_id (LQLClass *self);
Get the ID of this class. In relation to the TC command line options this is the part of the class identifier after the colon.
self : | The LQLClass instance. |
Returns : | The ID of the class |
gboolean lql_class_set_id (LQLClass *self, guint16 id);
Set the ID of this class. In relation to the TC command line options this is the part of the class identifier after the colon.
self : | The LQLClass instance. |
id : | The ID value. |
Returns : | TRUE on success, FALSE on failure. |
gboolean lql_class_set_parent (LQLClass *self, LQLElement *element);
Set the parent of this LQLClass to be the passed LQLElement.
self : | The LQLClass instance. |
element : | The LQLElement to set as the parent. |
Returns : | TRUE on success, FALSE on error. |
unsigned int lql_class_get_priority (LQLClass *self);
Get the priority value for this class.
self : | The LQLClass instance. |
Returns : | The priority value of this class. |
gboolean lql_class_set_priority (LQLClass *self, unsigned int priority);
Set the priority value of this class.
self : | The LQLClass instance. |
priority : | The priority value to set. |
Returns : | TRUE on success, FALSE on error. |
gboolean lql_class_fill_from_nlhdr (LQLClass *self, const struct nlmsghdr *hdr);
Fill in the instance variables for this instance of LQLClass to match the network class information in hdr.
self : | The LQLClass object to work with. |
hdr : | The class information from the kernel. |
Returns : | TRUE on success, FALSE on failure. |
guint32 lql_class_get_queueLength (LQLClass *self);
Get the current queue length for this Class.
self : | The LQLClass instance. |
Returns : | The current queue length. |
guint32 lql_class_get_backlog (LQLClass *self);
Get the current number of backlog packets.
self : | The LQLClass instance. |
Returns : | The number of backlog packets. |
guint32 lql_class_get_pps (LQLClass *self);
Get the current packets per second rate for this Class.
self : | The LQLClass instance. |
Returns : | The current PPS. |
guint64 lql_class_get_bytes (LQLClass *self);
Get the number of bytes that have been passed by this Class.
self : | The LQLClass instance. |
Returns : | The number of bytes. |
guint32 lql_class_get_packets (LQLClass *self);
Get the number of packets that have been passed by this Class.
self : | The LQLClass instance. |
Returns : | The number of packets. |
guint32 lql_class_get_overlimits (LQLClass *self);
Get the number of over limits packets.
self : | The LQLClass instance. |
Returns : | The number of over limits packets. |
guint32 lql_class_get_bps (LQLClass *self);
Get the current bytes per second rate for this Class.
self : | The LQLClass instance. |
Returns : | The current BPS. |
guint32 lql_class_get_drops (LQLClass *self);
Get the number of packets dropped by this Class.
self : | The LQLClass instance. |
Returns : | The number of drops. |
<< LQLQDiscNetem | LQLClassHTB >> |