eric6.Plugins.UiExtensionPlugins.PipInterface.PipSearchDialog

Module implementing a dialog to search PyPI.

Global Attributes

None

Classes

PipSearchDialog Class implementing a dialog to search PyPI.

Functions

None


PipSearchDialog

Class implementing a dialog to search PyPI.

Derived from

QDialog, Ui_PipSearchDialog

Class Attributes

Stopwords
VersionRole

Class Methods

None

Methods

PipSearchDialog Constructor
__detailsError Private method handling a details error.
__displayPackageDetails Private method to display the returned package details.
__finish Private slot performing the finishing actions.
__getPackageDownloadsData Private method to store the details data and get downloads information.
__install Private slot to install the selected packages.
__processSearchResult Private method to process the search result data from PyPI.
__score Private method to calculate some score for a search result.
__search Private method to perform the search.
__searchError Private method handling a search error.
__showDetails Private slot to show details about the selected package.
__transformHits Private method to convert the list returned from pypi into a packages list.
closeEvent Protected slot implementing a close event handler.
on_buttonBox_clicked Private slot called by a button of the button box clicked.
on_resultList_itemActivated Private slot reacting on an item activation.
on_resultList_itemSelectionChanged Private slot handling changes of the selection.
on_searchButton_clicked Private slot handling a press of the search button.
on_searchEdit_textChanged Private slot handling a change of the search term.

Static Methods

None

PipSearchDialog (Constructor)

PipSearchDialog(pip, indexUrl, parent=None)

Constructor

pip (Pip)
reference to the master object
indexUrl (str)
URL of XML RPC interface to the pypi index
parent (QWidget)
reference to the parent widget

PipSearchDialog.__detailsError

__detailsError(errorCode, errorString)

Private method handling a details error.

errorCode (int)
code of the error
errorString (str)
error message

PipSearchDialog.__displayPackageDetails

__displayPackageDetails(data)

Private method to display the returned package details.

data (tuple)
result data with downloads information in the first element

PipSearchDialog.__finish

__finish()

Private slot performing the finishing actions.

PipSearchDialog.__getPackageDownloadsData

__getPackageDownloadsData(packageVersion, data)

Private method to store the details data and get downloads information.

packageVersion (str)
version info
data (tuple)
result data with package details in the first element

PipSearchDialog.__install

__install(userSite=False)

Private slot to install the selected packages.

userSite (bool)
flag indicating to install to the user directory

PipSearchDialog.__processSearchResult

__processSearchResult(data)

Private method to process the search result data from PyPI.

data (tuple)
result data with hits in the first element

PipSearchDialog.__score

__score(name, summary)

Private method to calculate some score for a search result.

name (str)
name of the returned package
summary (str)
summary text for the package
Returns:
score value
Return Type:
int

PipSearchDialog.__search

__search()

Private method to perform the search.

PipSearchDialog.__searchError

__searchError(errorCode, errorString)

Private method handling a search error.

errorCode (int)
code of the error
errorString (str)
error message

PipSearchDialog.__showDetails

__showDetails()

Private slot to show details about the selected package.

PipSearchDialog.__transformHits

__transformHits(hits)

Private method to convert the list returned from pypi into a packages list.

hits (list of dict)
list returned from pypi
Returns:
list of packages
Return Type:
list of dict

PipSearchDialog.closeEvent

closeEvent(e)

Protected slot implementing a close event handler.

e (QCloseEvent)
close event

PipSearchDialog.on_buttonBox_clicked

on_buttonBox_clicked(button)

Private slot called by a button of the button box clicked.

button (QAbstractButton)
button that was clicked

PipSearchDialog.on_resultList_itemActivated

on_resultList_itemActivated(item, column)

Private slot reacting on an item activation.

item (QTreeWidgetItem)
reference to the activated item
column (int)
activated column

PipSearchDialog.on_resultList_itemSelectionChanged

on_resultList_itemSelectionChanged()

Private slot handling changes of the selection.

PipSearchDialog.on_searchButton_clicked

on_searchButton_clicked()

Private slot handling a press of the search button.

PipSearchDialog.on_searchEdit_textChanged

on_searchEdit_textChanged(txt)

Private slot handling a change of the search term.

txt (str)
search term
Up