Package Camelot :: Package camelot :: Package view :: Package proxy :: Module queryproxy :: Class QueryTableProxy |
[frames] | no frames]

# Class QueryTableProxy

source code

The QueryTableProxy contains a limited copy of the data in the Elixir model, which is fetched from the database to be used as the model for a QTableView

Instance Methods
__init__(self, admin, query_getter, columns_getter, max_number_of_rows=10, edits=None) @param query_getter: a model_thread function that returns a query | source code
get_query_getter(self) | source code
getRowCount(*args, **kwargs) | source code
setQuery(*args, **kwargs) Set the query and refresh the view | source code
get_collection_getter(self) | source code
sort(*args, **kwargs) reimplementation of the QAbstractItemModel its sort function | source code
append(self, o) Add an object to this collection, used when inserting a new row, overwrite this method for specific behaviour in subclasses | source code
remove(self, o) | source code
getData(*args, **kwargs) Generator for all the data queried by this proxy | source code
Inherited from `collection_proxy.CollectionProxy`: `columnCount`, `copy_row`, `data`, `flags`, `getColumns`, `getItemDelegate`, `get_admin`, `get_validator`, `handleEntityCreate`, `handleEntityDelete`, `handleEntityUpdate`, `handleRowUpdate`, `hasUnflushedRows`, `headerData`, `insertEntityInstance`, `insertRow`, `map_to_source`, `refresh`, `removeEntityInstance`, `removeRow`, `revertRow`, `rowCount`, `setColumns`, `setData`, `setRowCount`, `set_collection_getter`, `updateUnflushedRows` Inherited from `PyQt4.QtCore.QAbstractTableModel`: `dropMimeData`, `hasChildren`, `index`, `parent` Inherited from `PyQt4.QtCore.QAbstractItemModel`: `beginInsertColumns`, `beginInsertRows`, `beginMoveColumns`, `beginMoveRows`, `beginRemoveColumns`, `beginRemoveRows`, `beginResetModel`, `buddy`, `canFetchMore`, `changePersistentIndex`, `changePersistentIndexList`, `columnsAboutToBeInserted`, `columnsAboutToBeMoved`, `columnsAboutToBeRemoved`, `columnsInserted`, `columnsMoved`, `columnsRemoved`, `createIndex`, `dataChanged`, `decodeData`, `encodeData`, `endInsertColumns`, `endInsertRows`, `endMoveColumns`, `endMoveRows`, `endRemoveColumns`, `endRemoveRows`, `endResetModel`, `fetchMore`, `hasIndex`, `headerDataChanged`, `insertColumn`, `insertColumns`, `insertRows`, `itemData`, `layoutAboutToBeChanged`, `layoutChanged`, `match`, `mimeData`, `mimeTypes`, `modelAboutToBeReset`, `modelReset`, `persistentIndexList`, `removeColumn`, `removeColumns`, `removeRows`, `reset`, `revert`, `roleNames`, `rowsAboutToBeInserted`, `rowsAboutToBeMoved`, `rowsAboutToBeRemoved`, `rowsInserted`, `rowsMoved`, `rowsRemoved`, `setHeaderData`, `setItemData`, `setRoleNames`, `setSupportedDragActions`, `sibling`, `span`, `submit`, `supportedDragActions`, `supportedDropActions` Inherited from `PyQt4.QtCore.QObject`: `blockSignals`, `childEvent`, `children`, `connect`, `connectNotify`, `customEvent`, `deleteLater`, `destroyed`, `disconnect`, `disconnectNotify`, `dumpObjectInfo`, `dumpObjectTree`, `dynamicPropertyNames`, `emit`, `event`, `eventFilter`, `findChild`, `findChildren`, `inherits`, `installEventFilter`, `isWidgetType`, `killTimer`, `metaObject`, `moveToThread`, `objectName`, `property`, `pyqtConfigure`, `receivers`, `removeEventFilter`, `sender`, `setObjectName`, `setParent`, `setProperty`, `signalsBlocked`, `startTimer`, `thread`, `timerEvent`, `tr`, `trUtf8` Inherited from `sip.simplewrapper`: `__delattr__`, `__getattribute__`, `__new__`, `__setattr__` Inherited from `object`: `__format__`, `__hash__`, `__reduce__`, `__reduce_ex__`, `__repr__`, `__sizeof__`, `__str__`, `__subclasshook__`

Class Variables
Inherited from `collection_proxy.CollectionProxy`: `header_icon`, `item_delegate_changed_signal`, `rows_removed_signal` Inherited from `PyQt4.QtCore.QObject`: `staticMetaObject`

Properties
Inherited from `object`: `__class__`

Method Details

### __init__(self, admin, query_getter, columns_getter, max_number_of_rows=10, edits=None) (Constructor) | source code
@param query_getter: a model_thread function that returns a query Overrides: object.__init__

### getRowCount(*args, **kwargs) | source code
Decorators: `@model_function` Overrides: collection_proxy.CollectionProxy.getRowCount

### setQuery(*args, **kwargs) | source code
Set the query and refresh the view Decorators: `@gui_function`

### get_collection_getter(self) | source code
Overrides: collection_proxy.CollectionProxy.get_collection_getter

### sort(*args, **kwargs) | source code
reimplementation of the QAbstractItemModel its sort function Decorators: `@gui_function` Overrides: PyQt4.QtCore.QAbstractItemModel.sort

### append(self, o) | source code
Add an object to this collection, used when inserting a new row, overwrite this method for specific behaviour in subclasses Overrides: collection_proxy.CollectionProxy.append

### remove(self, o) | source code
Overrides: collection_proxy.CollectionProxy.remove

### getData(*args, **kwargs) | source code
Generator for all the data queried by this proxy Decorators: `@model_function` Overrides: collection_proxy.CollectionProxy.getData