Main Page | Class Hierarchy | Class List | File List | Class Members | File Members

YQPkgConflict Class Reference

Root item for each individual conflict. More...

#include <YQPkgConflictList.h>

Inheritance diagram for YQPkgConflict:

QY2ListViewItem List of all members.

Public Member Functions

 YQPkgConflict (YQPkgConflictList *parentList, const PkgDep::ErrorResult &errorResult)
virtual ~YQPkgConflict ()
PkgDep::ErrorResulterrorResult ()
bool needAlternative ()
bool hasCollisions ()
bool hasOpenRequirements ()
void applyResolution ()
bool isIgnored ()
void ignore ()

Static Public Member Functions

bool isIgnored (const QString &conflictHeader)
void ignore (const QString &conflictHeader)
void resetIgnoredConflicts ()
void saveIgnoredConflicts ()
void loadIgnoredConflicts ()
bool haveIgnoredConflicts ()
QAction * actionResetIgnoredConflicts (YQPkgConflictDialog *dialog=0)
void updateActions ()

Protected Member Functions

void formatHeading ()
void dumpLists ()
void dumpList (QListViewItem *parent, PkgDep::RelInfoList &list, int splitThreshold=-1, const QString &header=QString::null)
void addResolutionSuggestions ()
void addUndoResolution (QY2CheckListItem *parent)
void addAlternativesList (QY2CheckListItem *parent)
void addDeleteConflictsResolution (QY2CheckListItem *parent)
void addDeleteReferersResolution (QY2CheckListItem *parent)
void addIgnoreResolution (QY2CheckListItem *parent)
void dumpDeleteList (QListViewItem *parent, PkgDep::SolvableList &solvablelist)
void bruteForceDelete (PkgDep::SolvableList &solvablelist)
virtual void paintCell (QPainter *painter, const QColorGroup &colorGroup, int column, int width, int alignment)

Protected Attributes

PMObjectPtr _pmObj
bool _isPkg
QString _shortName
QString _fullName
PMSelectable::UI_Status _status
PMSelectable::UI_Status _undo_status
bool _canIgnore
QListViewItem * _resolutionsHeader
PkgDep::ErrorResult _conflict
YQPkgConflictList_parentList

Static Protected Attributes

QMap< QString, bool > _ignore
QAction * _actionResetIgnoredConflicts = 0

Detailed Description

Root item for each individual conflict.


Constructor & Destructor Documentation

YQPkgConflict::YQPkgConflict YQPkgConflictList parentList,
const PkgDep::ErrorResult errorResult
 

Constructor.

virtual YQPkgConflict::~YQPkgConflict  )  [inline, virtual]
 

Destructor.


Member Function Documentation

QAction * YQPkgConflict::actionResetIgnoredConflicts YQPkgConflictDialog dialog = 0  )  [static]
 

Returns a pointer to the one and only internal QAction that resets ignored dependency conflicts. If none exists yet, it will be created.

'dialog' is the conflict dialog this action is connected to.

void YQPkgConflict::addAlternativesList QY2CheckListItem parent  )  [protected]
 

Add a list of alternatives if there are any.

void YQPkgConflict::addDeleteConflictsResolution QY2CheckListItem parent  )  [protected]
 

Add resolution suggestion: Delete all conflicting packages.

void YQPkgConflict::addDeleteReferersResolution QY2CheckListItem parent  )  [protected]
 

Add brute force resolution suggestion: Delete all dependent packages.

void YQPkgConflict::addIgnoreResolution QY2CheckListItem parent  )  [protected]
 

Add resolution suggestion: Ignore conflict, risk inconsistent system

void YQPkgConflict::addResolutionSuggestions  )  [protected]
 

Add suggestions how to resolve this conflict.

void YQPkgConflict::addUndoResolution QY2CheckListItem parent  )  [protected]
 

Add resolution suggestion: Undo what caused this conflict ( i.e. don't remove, don't install, ... ).

void YQPkgConflict::applyResolution  ) 
 

Apply the choices the user made.

void YQPkgConflict::bruteForceDelete PkgDep::SolvableList solvablelist  )  [protected]
 

Remove everything in the remove list.

void YQPkgConflict::dumpDeleteList QListViewItem *  parent,
PkgDep::SolvableList solvablelist
[protected]
 

Dump the specified list (remove_to_solve_conflict/remove_referers) into the conflict list.

void YQPkgConflict::dumpList QListViewItem *  parent,
PkgDep::RelInfoList list,
int  splitThreshold = -1,
const QString &  header = QString::null
[protected]
 

Dump a list of package relations into the conflict list: Create a new list entry for each list entry. If 'header' is non-null, create a bracketing list item with text 'header' and insert the list items below that new item. Splits into a sublist at ( about ) 'splitThreshold' if this is > 1. Does nothing if the list is empty.

void YQPkgConflict::dumpLists  )  [protected]
 

Dump all relevant lists from the internal ErrorResult into the conflict list.

PkgDep::ErrorResult& YQPkgConflict::errorResult  )  [inline]
 

Access the internal ErrorResult.

void YQPkgConflict::formatHeading  )  [protected]
 

Format the text heading line for this item.

bool YQPkgConflict::hasCollisions  )  [inline]
 

Returns if this package collides with other packages.

bool YQPkgConflict::hasOpenRequirements  )  [inline]
 

Returns if this package has open ( unresolved ) requirements.

bool YQPkgConflict::haveIgnoredConflicts  )  [static]
 

Returns 'true' if there are any ignored conflicts, 'false' otherwise.

void YQPkgConflict::ignore const QString &  conflictHeader  )  [static]
 

Ignore a conflict with header ( first text line in list ) 'conflictHeader'.

void YQPkgConflict::ignore  ) 
 

Ignore this conflict - i.e. add it to the ignore list.

bool YQPkgConflict::isIgnored const QString &  conflictHeader  )  [static]
 

Check if a conflict with header ( first text line in list ) 'conflictHeader is ignored.

bool YQPkgConflict::isIgnored  ) 
 

Check if this conflict with header should be ignored.

void YQPkgConflict::loadIgnoredConflicts  )  [static]
 

Load ignored conflicts from ( predefined ) file.

bool YQPkgConflict::needAlternative  )  [inline]
 

Returns if this conflict needs an alternative from a list.

void YQPkgConflict::paintCell QPainter *  painter,
const QColorGroup &  colorGroup,
int  column,
int  width,
int  alignment
[protected, virtual]
 

Paint method. Reimplemented from QListViewItem a different font can be used.

Reimplemented from QY2ListViewItem.

Reimplemented from QY2ListViewItem.

void YQPkgConflict::resetIgnoredConflicts  )  [static]
 

Reset all ignored conflicts as if the user had never selected any conflict to ignore.

void YQPkgConflict::saveIgnoredConflicts  )  [static]
 

Save all ignored conflicts to ( predefined ) file.

void YQPkgConflict::updateActions  )  [static]
 

Update the enabled / disabled state of all internal QActions ( that are created yet - this method will not create any if they don't exist yet ).


Member Data Documentation

QAction * YQPkgConflict::_actionResetIgnoredConflicts = 0 [static, protected]
 

bool YQPkgConflict::_canIgnore [protected]
 

PkgDep::ErrorResult YQPkgConflict::_conflict [protected]
 

QString YQPkgConflict::_fullName [protected]
 

QMap< QString, bool > YQPkgConflict::_ignore [static, protected]
 

Conflicts that are to be ignored.

bool YQPkgConflict::_isPkg [protected]
 

YQPkgConflictList* YQPkgConflict::_parentList [protected]
 

PMObjectPtr YQPkgConflict::_pmObj [protected]
 

QListViewItem* YQPkgConflict::_resolutionsHeader [protected]
 

QString YQPkgConflict::_shortName [protected]
 

PMSelectable::UI_Status YQPkgConflict::_status [protected]
 

PMSelectable::UI_Status YQPkgConflict::_undo_status [protected]
 


The documentation for this class was generated from the following files:
Generated on Fri Oct 14 19:03:48 2005 for yast2-qt by doxygen 1.3.6