CallbackList

class glue.external.echo.CallbackList(callback, *args, **kwargs)

Bases: list

A list that calls a callback function when it is modified.

The first argument should be the callback function (which takes no arguments), and subsequent arguments are as for list.

Methods Summary

append(self, value)

clear(self)

extend(self, iterable)

insert(self, index, value)

L.insert(index, object) – insert object before index

pop(self[, index])

Raises IndexError if list is empty or index is out of range.

remove(self, value)

Raises ValueError if the value is not present.

reverse(self)

L.reverse() – reverse IN PLACE

sort(self[, key, reverse])

Methods Documentation

append(self, value)
clear(self)
extend(self, iterable)
insert(self, index, value)

L.insert(index, object) – insert object before index

pop(self, index=-1)

Raises IndexError if list is empty or index is out of range.

remove(self, value)

Raises ValueError if the value is not present.

reverse(self)

L.reverse() – reverse IN PLACE

sort(self, key=None, reverse=False)