# eric6.UI.BrowserModel

Module implementing the browser model.

### Global Attributes

BrowserItemAttribute
BrowserItemAttributes
BrowserItemClass
BrowserItemCoding
BrowserItemDirectory
BrowserItemFile
BrowserItemImport
BrowserItemImports
BrowserItemMethod
BrowserItemRoot
BrowserItemSysPath

### Classes

BrowserClassAttributeItem | Class implementing the data structure for browser class attribute items.
BrowserClassAttributesItem | Class implementing the data structure for browser class attributes items.
BrowserClassItem | Class implementing the data structure for browser class items.
BrowserCodingItem | Class implementing the data structure for browser coding items.
BrowserDirectoryItem | Class implementing the data structure for browser directory items.
BrowserFileItem | Class implementing the data structure for browser file items.
BrowserGlobalsItem | Class implementing the data structure for browser globals items.
BrowserImportItem | Class implementing the data structure for browser imported module and imported names items.
BrowserImportsItem | Class implementing the data structure for browser import items.
BrowserItem | Class implementing the data structure for browser items.
BrowserMethodItem | Class implementing the data structure for browser method items.
BrowserModel | Class implementing the browser model.
BrowserSysPathItem | Class implementing the data structure for browser sys.path items.

### Functions

None

## BrowserClassAttributeItem

Class implementing the data structure for browser class attribute items.

### Derived from

BrowserItem

### Class Attributes

None

### Class Methods

None

### Methods

BrowserClassAttributeItem | Constructor
attributeObject | Public method returning the class object.
fileName | Public method returning the filename.
isPublic | Public method returning the public visibility status.
lessThan | Public method to check, if the item is less than the other one.
lineno | Public method returning the line number defining this object.
linenos | Public method returning the line numbers this object is assigned to.

### Static Methods

None

#### BrowserClassAttributeItem (Constructor)

BrowserClassAttributeItem(parent, attribute, isClass=False)

Constructor

parent
  parent item
attribute
  reference to the attribute object
isClass
  flag indicating a class attribute (boolean)

#### BrowserClassAttributeItem.attributeObject

attributeObject()

Public method returning the class object.

Returns:
  reference to the class object

#### BrowserClassAttributeItem.fileName

fileName()

Public method returning the filename.

Returns:
  filename (string)

#### BrowserClassAttributeItem.isPublic

isPublic()

Public method returning the public visibility status.

Returns:
  flag indicating public visibility (boolean)

#### BrowserClassAttributeItem.lessThan

lessThan(other, column, order)

Public method to check, if the item is less than the other one.

other
  reference to item to compare against (BrowserItem)
column
  column number to use for the comparison (integer)
order
  sort order (Qt.SortOrder) (for special sorting)

Returns:
  true, if this item is less than other (boolean)

#### BrowserClassAttributeItem.lineno

lineno()

Public method returning the line number defining this object.

Returns:
  line number defining the object (integer)

#### BrowserClassAttributeItem.linenos

linenos()

Public method returning the line numbers this object is assigned to.

Returns:
  line number the object is assigned to (list of integers)

Up

## BrowserClassAttributesItem

Class implementing the data structure for browser class attributes items.

### Derived from

BrowserItem

### Class Attributes

None

### Class Methods

None

### Methods

BrowserClassAttributesItem | Constructor
attributes | Public method returning the attribute list.
isClassAttributes | Public method returning the attributes type.
lessThan | Public method to check, if the item is less than the other one.
name | Public method to return the name of the item.

### Static Methods

None

#### BrowserClassAttributesItem (Constructor)

BrowserClassAttributesItem(parent, attributes, text, isClass=False)

Constructor

parent
  parent item
attributes
  list of attributes
text
  text to be shown by this item (string)
isClass
  flag indicating class attributes (boolean)

#### BrowserClassAttributesItem.attributes

attributes()

Public method returning the attribute list.

Returns:
  reference to the list of attributes

#### BrowserClassAttributesItem.isClassAttributes

isClassAttributes()

Public method returning the attributes type.

Returns:
  flag indicating class attributes (boolean)

#### BrowserClassAttributesItem.lessThan

lessThan(other, column, order)

Public method to check, if the item is less than the other one.

other
  reference to item to compare against (BrowserItem)
column
  column number to use for the comparison (integer)
order
  sort order (Qt.SortOrder) (for special sorting)

Returns:
  true, if this item is less than other (boolean)

#### BrowserClassAttributesItem.name

name()

Public method to return the name of the item.

Returns:
  name of the item (string)

Up

## BrowserClassItem

Class implementing the data structure for browser class items.

### Derived from

BrowserItem

### Class Attributes

None

### Class Methods

None

### Methods

BrowserClassItem | Constructor
boundaries | Public method returning the boundaries of the method definition.
classObject | Public method returning the class object.
fileName | Public method returning the filename.
isPublic | Public method returning the public visibility status.
lessThan | Public method to check, if the item is less than the other one.
lineno | Public method returning the line number defining this object.
name | Public method to return the name of the item.

### Static Methods

None

#### BrowserClassItem (Constructor)

BrowserClassItem(parent, cl, filename)

Constructor

parent
  parent item
cl
  Class object to be shown
filename
  filename of the file defining this class

#### BrowserClassItem.boundaries

boundaries()

Public method returning the boundaries of the method definition.

Returns:
  tuple with start end end line number (integer, integer)

#### BrowserClassItem.classObject

classObject()

Public method returning the class object.

Returns:
  reference to the class object

#### BrowserClassItem.fileName

fileName()

Public method returning the filename.

Returns:
  filename (string)

#### BrowserClassItem.isPublic

isPublic()

Public method returning the public visibility status.

Returns:
  flag indicating public visibility (boolean)

#### BrowserClassItem.lessThan

lessThan(other, column, order)

Public method to check, if the item is less than the other one.

other
  reference to item to compare against (BrowserItem)
column
  column number to use for the comparison (integer)
order
  sort order (Qt.SortOrder) (for special sorting)

Returns:
  true, if this item is less than other (boolean)

#### BrowserClassItem.lineno

lineno()

Public method returning the line number defining this object.

Returns:
  line number defining the object (integer)

#### BrowserClassItem.name

name()

Public method to return the name of the item.

Returns:
  name of the item (string)

Up

## BrowserCodingItem

Class implementing the data structure for browser coding items.

### Derived from

BrowserItem

### Class Attributes

None

### Class Methods

None

### Methods

BrowserCodingItem | Constructor
lessThan | Public method to check, if the item is less than the other one.

### Static Methods

None

#### BrowserCodingItem (Constructor)

BrowserCodingItem(parent, text)

Constructor

parent
  parent item
text
  text to be shown by this item (string)

#### BrowserCodingItem.lessThan

lessThan(other, column, order)

Public method to check, if the item is less than the other one.

other
  reference to item to compare against (BrowserItem)
column
  column number to use for the comparison (integer)
order
  sort order (Qt.SortOrder) (for special sorting)

Returns:
  true, if this item is less than other (boolean)

Up

## BrowserDirectoryItem

Class implementing the data structure for browser directory items.

### Derived from

BrowserItem

### Class Attributes

None

### Class Methods

None

### Methods

BrowserDirectoryItem | Constructor
dirName | Public method returning the directory name.
lessThan | Public method to check, if the item is less than the other one.
name | Public method to return the name of the item.
setName | Public method to set the directory name.

### Static Methods

None

#### BrowserDirectoryItem (Constructor)

BrowserDirectoryItem(parent, dinfo, full=True)

Constructor

parent
  parent item
dinfo
  dinfo is the string for the directory (string)
full
  flag indicating full pathname should be displayed (boolean)

#### BrowserDirectoryItem.dirName

dirName()

Public method returning the directory name.

Returns:
  directory name (string)

#### BrowserDirectoryItem.lessThan

lessThan(other, column, order)

Public method to check, if the item is less than the other one.

other
  reference to item to compare against (BrowserItem)
column
  column number to use for the comparison (integer)
order
  sort order (Qt.SortOrder) (for special sorting)

Returns:
  true, if this item is less than other (boolean)

#### BrowserDirectoryItem.name

name()

Public method to return the name of the item.

Returns:
  name of the item (string)

#### BrowserDirectoryItem.setName

setName(dinfo, full=True)

Public method to set the directory name.

dinfo
  dinfo is the string for the directory (string)
full
  flag indicating full pathname should be displayed (boolean)

Up

## BrowserFileItem

Class implementing the data structure for browser file items.

### Derived from

BrowserItem

### Class Attributes

None

### Class Methods

None

### Methods

BrowserFileItem | Constructor
dirName | Public method returning the directory name.
fileExt | Public method returning the file extension.
fileName | Public method returning the filename.
isDFile | Public method to check, if this file is a D file.
isDesignerFile | Public method to check, if this file is a Qt-Designer file.
isIdlFile | Public method to check, if this file is a CORBA IDL file.
isJavaScriptFile | Public method to check, if this file is a JavaScript file.
isLinguistFile | Public method to check, if this file is a Qt-Linguist file.
isMultiProjectFile | Public method to check, if this file is an eric multi project file.
isPixmapFile | Public method to check, if this file is a pixmap file.
isProjectFile | Public method to check, if this file is an eric project file.
isProtobufFile | Public method to check, if this file is a Google Protocol Buffer file.
isPython2File | Public method to check, if this file is a Python script.
isPython3File | Public method to check, if this file is a Python3 script.
isResourcesFile | Public method to check, if this file is a Qt-Resources file.
isRubyFile | Public method to check, if this file is a Ruby script.
isSvgFile | Public method to check, if this file is a SVG file.
lessThan | Public method to check, if the item is less than the other one.
moduleName | Public method returning the module name.
name | Public method to return the name of the item.
setName | Public method to set the directory name.

### Static Methods

None

#### BrowserFileItem (Constructor)

BrowserFileItem(parent, finfo, full=True, sourceLanguage="")

Constructor

parent
  parent item
finfo
  the string for the file (string)
full
  flag indicating full pathname should be displayed (boolean)
sourceLanguage
  source code language of the project (string)

#### BrowserFileItem.dirName

dirName()

Public method returning the directory name.

Returns:
  directory name (string)

#### BrowserFileItem.fileExt

fileExt()

Public method returning the file extension.

Returns:
  file extension (string)

#### BrowserFileItem.fileName

fileName()

Public method returning the filename.

Returns:
  filename (string)

#### BrowserFileItem.isDFile

isDFile()

Public method to check, if this file is a D file.

Returns:
  flag indicating a D file (boolean)

#### BrowserFileItem.isDesignerFile

isDesignerFile()

Public method to check, if this file is a Qt-Designer file.

Returns:
  flag indicating a Qt-Designer file (boolean)

#### BrowserFileItem.isIdlFile

isIdlFile()

Public method to check, if this file is a CORBA IDL file.

Returns:
  flag indicating a CORBA IDL file (boolean)

#### BrowserFileItem.isJavaScriptFile

isJavaScriptFile()

Public method to check, if this file is a JavaScript file.

Returns:
  flag indicating a JavaScript file (boolean)

#### BrowserFileItem.isLinguistFile

isLinguistFile()

Public method to check, if this file is a Qt-Linguist file.

Returns:
  flag indicating a Qt-Linguist file (boolean)

#### BrowserFileItem.isMultiProjectFile

isMultiProjectFile()

Public method to check, if this file is an eric multi project file.

Returns:
  flag indicating an eric project file (boolean)

#### BrowserFileItem.isPixmapFile

isPixmapFile()

Public method to check, if this file is a pixmap file.

Returns:
  flag indicating a pixmap file (boolean)

#### BrowserFileItem.isProjectFile

isProjectFile()

Public method to check, if this file is an eric project file.

Returns:
  flag indicating an eric project file (boolean)

#### BrowserFileItem.isProtobufFile

isProtobufFile()

Public method to check, if this file is a Google Protocol Buffer file.

Returns:
  flag indicating a protobuf file

Return Type:
  bool

#### BrowserFileItem.isPython2File

isPython2File()

Public method to check, if this file is a Python script.

Returns:
  flag indicating a Python file (boolean)

#### BrowserFileItem.isPython3File

isPython3File()

Public method to check, if this file is a Python3 script.

Returns:
  flag indicating a Python file (boolean)

#### BrowserFileItem.isResourcesFile

isResourcesFile()

Public method to check, if this file is a Qt-Resources file.

Returns:
  flag indicating a Qt-Resources file (boolean)

#### BrowserFileItem.isRubyFile

isRubyFile()

Public method to check, if this file is a Ruby script.

Returns:
  flag indicating a Ruby file (boolean)

#### BrowserFileItem.isSvgFile

isSvgFile()

Public method to check, if this file is a SVG file.

Returns:
  flag indicating a SVG file (boolean)

#### BrowserFileItem.lessThan

lessThan(other, column, order)

Public method to check, if the item is less than the other one.

other
  reference to item to compare against (BrowserItem)
column
  column number to use for the comparison (integer)
order
  sort order (Qt.SortOrder) (for special sorting)

Returns:
  true, if this item is less than other (boolean)

#### BrowserFileItem.moduleName

moduleName()

Public method returning the module name.

Returns:
  module name (string)

#### BrowserFileItem.name

name()

Public method to return the name of the item.

Returns:
  name of the item (string)

#### BrowserFileItem.setName

setName(finfo, full=True)

Public method to set the directory name.

finfo
  the string for the file (string)
full
  flag indicating full pathname should be displayed (boolean)

Up

## BrowserGlobalsItem

Class implementing the data structure for browser globals items.

### Derived from

BrowserClassAttributesItem

### Class Attributes

None

### Class Methods

None

### Methods

BrowserGlobalsItem | Constructor

### Static Methods

None

#### BrowserGlobalsItem (Constructor)

BrowserGlobalsItem(parent, attributes, text)

Constructor

parent
  parent item
attributes
  list of attributes
text
  text to be shown by this item (string)

Up

## BrowserImportItem

Class implementing the data structure for browser imported module and imported names items.

### Derived from

BrowserItem

### Class Attributes

None

### Class Methods

None

### Methods

BrowserImportItem | Constructor
fileName | Public method returning the filename.
lessThan | Public method to check, if the item is less than the other one.
lineno | Public method returning the line number of the first import.
linenos | Public method returning the line numbers of all imports.

### Static Methods

None

#### BrowserImportItem (Constructor)

BrowserImportItem(parent, text, filename, lineNumbers, isModule=True)

Constructor

parent
  parent item
text
  text to be shown by this item (string)
filename
  name of the file (string)
lineNumbers
  list of line numbers of the import statement (list of integer)
isModule
  flag indicating a module item entry (boolean)

#### BrowserImportItem.fileName

fileName()

Public method returning the filename.

Returns:
  filename (string)

#### BrowserImportItem.lessThan

lessThan(other, column, order)

Public method to check, if the item is less than the other one.

other
  reference to item to compare against (BrowserItem)
column
  column number to use for the comparison (integer)
order
  sort order (Qt.SortOrder) (for special sorting)

Returns:
  true, if this item is less than other (boolean)

#### BrowserImportItem.lineno

lineno()

Public method returning the line number of the first import.

Returns:
  line number of the first import (integer)

#### BrowserImportItem.linenos

linenos()

Public method returning the line numbers of all imports.

Returns:
  line numbers of all imports (list of integers)

Up

## BrowserImportsItem

Class implementing the data structure for browser import items.

### Derived from

BrowserItem

### Class Attributes

None

### Class Methods

None

### Methods

BrowserImportsItem | Constructor
lessThan | Public method to check, if the item is less than the other one.

### Static Methods

None

#### BrowserImportsItem (Constructor)

BrowserImportsItem(parent, text)

Constructor

parent
  parent item
text
  text to be shown by this item (string)

#### BrowserImportsItem.lessThan

lessThan(other, column, order)

Public method to check, if the item is less than the other one.

other
  reference to item to compare against (BrowserItem)
column
  column number to use for the comparison (integer)
order
  sort order (Qt.SortOrder) (for special sorting)

Returns:
  true, if this item is less than other (boolean)

Up

## BrowserItem

Class implementing the data structure for browser items.

### Derived from

object

### Class Attributes

None

### Class Methods

None

### Methods

BrowserItem | Constructor
appendChild | Public method to add a child to this item.
child | Public method to get a child id.
childCount | Public method to get the number of available child items.
children | Public method to get the ids of all child items.
columnCount | Public method to get the number of available data items.
data | Public method to get a specific data item.
getIcon | Public method to get the items icon.
isLazyPopulated | Public method to check, if this item should be populated lazyly.
isPopulated | Public method to chek, if this item is populated.
isPublic | Public method returning the public visibility status.
isSymlink | Public method to check, if the items is a symbolic link.
lessThan | Public method to check, if the item is less than the other one.
parent | Public method to get the reference to the parent item.
removeChild | Public method to remove a child.
removeChildren | Public method to remove all children.
row | Public method to get the row number of this item.
type | Public method to get the item type.

### Static Methods

None

#### BrowserItem (Constructor)

BrowserItem(parent, data)

Constructor

parent
  reference to the parent item
data
  single data of the item

#### BrowserItem.appendChild

appendChild(child)

Public method to add a child to this item.

child
  reference to the child item to add (BrowserItem)

#### BrowserItem.child

child(row)

Public method to get a child id.

row
  number of child to get the id of (integer)

Returns:
  reference to the child item (BrowserItem)

#### BrowserItem.childCount

childCount()

Public method to get the number of available child items.

Returns:
  number of child items (integer)

#### BrowserItem.children

children()

Public method to get the ids of all child items.

Returns:
  references to all child items (list of BrowserItem)

#### BrowserItem.columnCount

columnCount()

Public method to get the number of available data items.

Returns:
  number of data items (integer)

#### BrowserItem.data

data(column)

Public method to get a specific data item.

column
  number of the requested data item (integer)

Returns:
  stored data item

#### BrowserItem.getIcon

getIcon()

Public method to get the items icon.

Returns:
  the icon (QIcon)

#### BrowserItem.isLazyPopulated

isLazyPopulated()

Public method to check, if this item should be populated lazyly.

Returns:
  lazy population flag (boolean)

#### BrowserItem.isPopulated

isPopulated()

Public method to chek, if this item is populated.

Returns:
  population status (boolean)

#### BrowserItem.isPublic

isPublic()

Public method returning the public visibility status.

Returns:
  flag indicating public visibility (boolean)

#### BrowserItem.isSymlink

isSymlink()

Public method to check, if the items is a symbolic link.

Returns:
  flag indicating a symbolic link (boolean)

#### BrowserItem.lessThan

lessThan(other, column, order)

Public method to check, if the item is less than the other one.

other
  reference to item to compare against (BrowserItem)
column
  column number to use for the comparison (integer)
order
  sort order (Qt.SortOrder) (for special sorting)

Returns:
  true, if this item is less than other (boolean)

#### BrowserItem.parent

parent()

Public method to get the reference to the parent item.

Returns:
  reference to the parent item

#### BrowserItem.removeChild

removeChild(child)

Public method to remove a child.

child
  reference to the child to remove (BrowserItem)

#### BrowserItem.removeChildren

removeChildren()

Public method to remove all children.

#### BrowserItem.row

row()

Public method to get the row number of this item.

Returns:
  row number (integer)

#### BrowserItem.type

type()

Public method to get the item type.

Returns:
  type of the item

Up

## BrowserMethodItem

Class implementing the data structure for browser method items.

### Derived from

BrowserItem

### Class Attributes

None

### Class Methods

None

### Methods

BrowserMethodItem | Constructor
boundaries | Public method returning the boundaries of the method definition.
fileName | Public method returning the filename.
functionObject | Public method returning the function object.
isPublic | Public method returning the public visibility status.
lessThan | Public method to check, if the item is less than the other one.
lineno | Public method returning the line number defining this object.
name | Public method to return the name of the item.

### Static Methods

None

#### BrowserMethodItem (Constructor)

BrowserMethodItem(parent, fn, filename)

Constructor

parent
  parent item
fn
  Function object to be shown
filename
  filename of the file defining this class (string)

#### BrowserMethodItem.boundaries

boundaries()

Public method returning the boundaries of the method definition.

Returns:
  tuple with start end end line number (integer, integer)

#### BrowserMethodItem.fileName

fileName()

Public method returning the filename.

Returns:
  filename (string)

#### BrowserMethodItem.functionObject

functionObject()

Public method returning the function object.

Returns:
  reference to the function object

#### BrowserMethodItem.isPublic

isPublic()

Public method returning the public visibility status.

Returns:
  flag indicating public visibility (boolean)

#### BrowserMethodItem.lessThan

lessThan(other, column, order)

Public method to check, if the item is less than the other one.

other
  reference to item to compare against (BrowserItem)
column
  column number to use for the comparison (integer)
order
  sort order (Qt.SortOrder) (for special sorting)

Returns:
  true, if this item is less than other (boolean)

#### BrowserMethodItem.lineno

lineno()

Public method returning the line number defining this object.

Returns:
  line number defining the object (integer)

#### BrowserMethodItem.name

name()

Public method to return the name of the item.

Returns:
  name of the item (string)

Up

## BrowserModel

Class implementing the browser model.

### Derived from

QAbstractItemModel

### Class Attributes

None

### Class Methods

None

### Methods

BrowserModel | Constructor
__populateModel | Private method to populate the browser model.
_addItem | Protected slot to add an item.
_addWatchedItem | Protected method to watch an item.
_removeWatchedItem | Protected method to remove a watched item.
addItem | Public slot to add an item.
addTopLevelDir | Public method to add a new toplevel directory.
clear | Public method to clear the model.
columnCount | Public method to get the number of columns.
data | Public method to get data of an item.
directoryChanged | Public slot to handle the directoryChanged signal of the watcher.
flags | Public method to get the item flags.
hasChildren | Public method to check for the presence of child items.
headerData | Public method to get the header data.
index | Public method to create an index.
interpreterChanged | Public method to handle a change of the debug client's interpreter.
item | Public method to get a reference to an item.
parent | Public method to get the index of the parent object.
populateClassAttributesItem | Public method to populate a class attributes item's subtree.
populateClassItem | Public method to populate a class item's subtree.
populateDirectoryItem | Public method to populate a directory item's subtree.
populateFileItem | Public method to populate a file item's subtree.
populateItem | Public method to populate an item's subtree.
populateMethodItem | Public method to populate a method item's subtree.
populateSysPathItem | Public method to populate a sys.path item's subtree.
programChange | Public method to change the entry for the directory of file being debugged.
removeToplevelDir | Public method to remove a toplevel directory.
rowCount | Public method to get the number of rows.
saveToplevelDirs | Public slot to save the toplevel directories.

### Static Methods

None

#### BrowserModel (Constructor)

BrowserModel(parent=None, nopopulate=False)

Constructor

parent
  reference to parent object (QObject)
nopopulate=
  flag indicating to not populate the model (boolean)

#### BrowserModel.__populateModel

__populateModel()

Private method to populate the browser model.

#### BrowserModel._addItem

_addItem(itm, parentItem)

Protected slot to add an item.

itm
  reference to item to add (BrowserItem)
parentItem
  reference to item to add to (BrowserItem)

#### BrowserModel._addWatchedItem

_addWatchedItem(itm)

Protected method to watch an item.

itm
  item to be watched (BrowserDirectoryItem)

#### BrowserModel._removeWatchedItem

_removeWatchedItem(itm)

Protected method to remove a watched item.

itm
  item to be removed (BrowserDirectoryItem)

#### BrowserModel.addItem

addItem(itm, parent=None)

Public slot to add an item.

itm
  item to add (BrowserItem)
parent
  index of parent item (QModelIndex)

#### BrowserModel.addTopLevelDir

addTopLevelDir(dirname)

Public method to add a new toplevel directory.

dirname
  name of the new toplevel directory (string)

#### BrowserModel.clear

clear()

Public method to clear the model.

#### BrowserModel.columnCount

columnCount(parent=None)

Public method to get the number of columns.

parent
  index of parent item (QModelIndex)

Returns:
  number of columns (integer)

#### BrowserModel.data

data(index, role)

Public method to get data of an item.

index
  index of the data to retrieve (QModelIndex)
role
  role of data (Qt.ItemDataRole)

Returns:
  requested data

#### BrowserModel.directoryChanged

directoryChanged(path)

Public slot to handle the directoryChanged signal of the watcher.

path
  path of the directory (string)

#### BrowserModel.flags

flags(index)

Public method to get the item flags.

index
  index of the data to retrieve (QModelIndex)

Returns:
  requested flags (Qt.ItemFlags)

#### BrowserModel.hasChildren

hasChildren(parent=None)

Public method to check for the presence of child items.

We always return True for normal items in order to do lazy population of the tree.

parent
  index of parent item (QModelIndex)

Returns:
  flag indicating the presence of child items (boolean)

#### BrowserModel.headerData

headerData(section, orientation, role=Qt.DisplayRole)

Public method to get the header data.

section
  number of section to get data for (integer)
orientation
  header orientation (Qt.Orientation)
role
  role of data (Qt.ItemDataRole)

Returns:
  requested header data

#### BrowserModel.index

index(row, column, parent=None)

Public method to create an index.

row
  row number of the new index (integer)
column
  column number of the new index (integer)
parent
  index of parent item (QModelIndex)

Returns:
  index object (QModelIndex)

#### BrowserModel.interpreterChanged

interpreterChanged(interpreter)

Public method to handle a change of the debug client's interpreter.

interpreter
  interpreter of the debug client (string)

#### BrowserModel.item

item(index)

Public method to get a reference to an item.

index
  index of the data to retrieve (QModelIndex)

Returns:
  requested item reference (BrowserItem)

#### BrowserModel.parent

parent(index)

Public method to get the index of the parent object.

index
  index of the item (QModelIndex)

Returns:
  index of parent item (QModelIndex)

#### BrowserModel.populateClassAttributesItem

populateClassAttributesItem(parentItem, repopulate=False)

Public method to populate a class attributes item's subtree.

parentItem
  reference to the class attributes item to be populated
repopulate
  flag indicating a repopulation (boolean)

#### BrowserModel.populateClassItem

populateClassItem(parentItem, repopulate=False)

Public method to populate a class item's subtree.

parentItem
  reference to the class item to be populated
repopulate
  flag indicating a repopulation (boolean)

#### BrowserModel.populateDirectoryItem

populateDirectoryItem(parentItem, repopulate=False)

Public method to populate a directory item's subtree.

parentItem
  reference to the directory item to be populated
repopulate
  flag indicating a repopulation (boolean)

#### BrowserModel.populateFileItem

populateFileItem(parentItem, repopulate=False)

Public method to populate a file item's subtree.

parentItem
  reference to the file item to be populated
repopulate
  flag indicating a repopulation (boolean)

#### BrowserModel.populateItem

populateItem(parentItem, repopulate=False)

Public method to populate an item's subtree.

parentItem
  reference to the item to be populated
repopulate
  flag indicating a repopulation (boolean)

#### BrowserModel.populateMethodItem

populateMethodItem(parentItem, repopulate=False)

Public method to populate a method item's subtree.

parentItem
  reference to the method item to be populated
repopulate
  flag indicating a repopulation (boolean)

#### BrowserModel.populateSysPathItem

populateSysPathItem(parentItem, repopulate=False)

Public method to populate a sys.path item's subtree.

parentItem
  reference to the sys.path item to be populated
repopulate
  flag indicating a repopulation (boolean)

#### BrowserModel.programChange

programChange(dirname)

Public method to change the entry for the directory of file being debugged.

dirname
  name of the directory containing the file (string)

#### BrowserModel.removeToplevelDir

removeToplevelDir(index)

Public method to remove a toplevel directory.

index
  index of the toplevel directory to be removed (QModelIndex)

#### BrowserModel.rowCount

rowCount(parent=None)

Public method to get the number of rows.

parent
  index of parent item (QModelIndex)

Returns:
  number of rows (integer)

#### BrowserModel.saveToplevelDirs

saveToplevelDirs()

Public slot to save the toplevel directories.

Up

## BrowserSysPathItem

Class implementing the data structure for browser sys.path items.

### Derived from

BrowserItem

### Class Attributes

None

### Class Methods

None

### Methods

BrowserSysPathItem | Constructor
name | Public method to return the name of the item.

### Static Methods

None

#### BrowserSysPathItem (Constructor)

BrowserSysPathItem(parent)

Constructor

parent
  parent item

#### BrowserSysPathItem.name

name()

Public method to return the name of the item.

Returns:
  name of the item (string)

Up