## OobsList

OobsList — Object to deal with several configuration elements

## Functions

gboolean | oobs_list_get_iter_first ()
gboolean | oobs_list_iter_next ()
gboolean | oobs_list_remove ()
void | oobs_list_append ()
void | oobs_list_prepend ()
void | oobs_list_insert_after ()
void | oobs_list_insert_before ()
GObject * | oobs_list_get ()
void | oobs_list_set ()
void | oobs_list_clear ()
gint | oobs_list_get_n_items ()
OobsListIter * | oobs_list_iter_copy ()
void | oobs_list_iter_free ()

## Properties

gpointer | contained-type | Write / Construct Only

## Object Hierarchy

        GBoxed
        ╰── OobsListIter
        GObject
        ╰── OobsList

## Description

## Functions

### oobs_list_get_iter_first ()

    gboolean
    oobs_list_get_iter_first (OobsList *list,
                              OobsListIter *iter);

Initializes `iter` the iterator pointing to the first element in `list` . if `list` is empty, then FALSE is returned, and `iter` is not initialized.

#### Parameters

list | An OobsList |
iter | An uninitialized OobsListIter |

#### Returns

TRUE if `iter` was set

### oobs_list_iter_next ()

    gboolean
    oobs_list_iter_next (OobsList *list,
                         OobsListIter *iter);

Sets `iter` to point to the element following it. If there's no next `iter` , of if `iter` was invalid for `list` , FALSE is returned, and `iter` is set to invalid.

#### Parameters

list | An OobsList |
iter | A valid OobsListIter pointing to an element in `list` |

#### Returns

TRUE if iter has been correctly changed to the next element

### oobs_list_remove ()

    gboolean
    oobs_list_remove (OobsList *list,
                      OobsListIter *iter);

Removes an element pointed by `iter` from `list` . This function will not be effective if `list` is locked, or if `iter` doesn't point to an element contained in `list` .

#### Parameters

list | An OobsList |
iter | A valid OobsListIter pointing to an element in `list` |

#### Returns

TRUE if the element was correctly removed

### oobs_list_append ()

    void
    oobs_list_append (OobsList *list,
                      OobsListIter *iter);

Appends a new element to `list` . `iter` will be changed to point to this element, to fill in values, you need to call `oobs_list_set()`.

#### Parameters

list | An OobsList |
iter | An unset OobsListIter to set to the new element |

### oobs_list_prepend ()

    void
    oobs_list_prepend (OobsList *list,
                       OobsListIter *iter);

Prepends a new element to `list` . `iter` will be changed to point to this element, to fill in values, you need to call `oobs_list_set()`.

#### Parameters

list | An OobsList |
iter | An unset OobsListIter to set to the new element |

### oobs_list_insert_after ()

    void
    oobs_list_insert_after (OobsList *list,
                            OobsListIter *anchor,
                            OobsListIter *iter);

Inserts a new element after `anchor` . `iter` will be changed to point to this element, to fill in values, you need to call `oobs_list_set()`.

#### Parameters

list | An OobsList |
anchor | A valid OobsListIter |
iter | An unset OobsListIter to set to the new element |

### oobs_list_insert_before ()

    void
    oobs_list_insert_before (OobsList *list,
                             OobsListIter *anchor,
                             OobsListIter *iter);

Inserts a new element before `anchor` . `iter` will be changed to point to this element, to fill in values, you need to call `oobs_list_set()`.

#### Parameters

list | An OobsList |
anchor | A valid OobsListIter |
iter | An unset OobsListIter to set to the new element |

### oobs_list_get ()

    GObject *
    oobs_list_get (OobsList *list,
                   OobsListIter *iter);

Retrieves a reference to the element referenced by OobsListIter.

#### Parameters

list | an OobsList |
iter | a valid OobsListIter for the element being get |

#### Returns

the element referenced by `iter`

### oobs_list_set ()

    void
    oobs_list_set (OobsList *list,
                   OobsListIter *iter,
                   gpointer data);

Sets the data for the element referenced by OobsListIter. This function will not be effective if the list is locked, or if `data` GType is different to the data contained in OobsList.

#### Parameters

list | an OobsList |
iter | a valid OobsListIter for the element being set |
data | a pointer to the data being set |

### oobs_list_clear ()

    void
    oobs_list_clear (OobsList *list);

Removes all contents from an OobsList. This function will not be effective if the list is locked.

#### Parameters

list | an OobsList |

### oobs_list_get_n_items ()

    gint
    oobs_list_get_n_items (OobsList *list);

Returns the number of elements that the list contains.

#### Parameters

list | An OobsList. |

#### Returns

the number of elements.

### oobs_list_iter_copy ()

    OobsListIter *
    oobs_list_iter_copy (OobsListIter *iter);

Returns a newly allocated copy of the given iterator. This function is not intended for use in applications, because you can just copy the structs by value (OobsListIter new_iter = iter;). You must free this iter with `oobs_list_iter_free()`.

#### Parameters

iter | An OobsListIter. |

#### Returns

A newly allocated iterator.

### oobs_list_iter_free ()

    void
    oobs_list_iter_free (OobsListIter *iter);

Frees an iterator that has been allocated in the heap.

#### Parameters

iter | An OobsListIter. |

## Property Details

### The `“contained-type”` property

      “contained-type”           gpointer

GType contained in the list.

Owner: OobsList

Flags: Write / Construct Only

## See Also

OobsObject