• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdepim API Reference
  • KDE Home
  • Contact Us
 

messagelist

  • MessageList
  • Core
  • ModelInvariantIndex
Classes | Public Member Functions | List of all members
MessageList::Core::ModelInvariantIndex Class Reference

#include <modelinvariantindex.h>

Inheritance diagram for MessageList::Core::ModelInvariantIndex:
Inheritance graph
[legend]

Classes

class  Private
 

Public Member Functions

 ModelInvariantIndex ()
 
virtual ~ModelInvariantIndex ()
 
int currentModelIndexRow ()
 
bool isValid () const
 

Detailed Description

An invariant index that can be ALWAYS used to reference an item inside a QAbstractItemModel.

This class is meant to be used together with ModelInvariantRowMapper.

Definition at line 44 of file modelinvariantindex.h.

Constructor & Destructor Documentation

ModelInvariantIndex::ModelInvariantIndex ( )
explicit

Definition at line 28 of file modelinvariantindex.cpp.

ModelInvariantIndex::~ModelInvariantIndex ( )
virtual

Definition at line 34 of file modelinvariantindex.cpp.

Member Function Documentation

int ModelInvariantIndex::currentModelIndexRow ( )

Returns the current model index row for this invariant index.

This function calls the mapper and asks it to perform the persistent mapping. If this index isn't valid then the returned value is -1.

If you actually own the row mapper then you may save some clock cycles by calling the modelInvariantIndexToModelIndexRow() by your own. If you don't own the mapper then this function is the only way to go.

Definition at line 47 of file modelinvariantindex.cpp.

bool ModelInvariantIndex::isValid ( ) const

Returns true if this ModelInvariantIndex is valid, that is, it has been attacched to a ModelInvariantRowMapper.

Returns false otherwise. An invalid index will always map to the current row -1 (which is invalid as QModelIndex row).

Definition at line 42 of file modelinvariantindex.cpp.


The documentation for this class was generated from the following files:
  • modelinvariantindex.h
  • modelinvariantindex.cpp
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:55:32 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

messagelist

Skip menu "messagelist"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members

kdepim API Reference

Skip menu "kdepim API Reference"
  • akonadi_next
  • akregator
  • blogilo
  • calendarsupport
  • console
  •   kabcclient
  •   konsolekalendar
  • kaddressbook
  • kalarm
  •   lib
  • kdgantt2
  • kjots
  • kleopatra
  • kmail
  • knode
  • knotes
  • kontact
  • korgac
  • korganizer
  • ktimetracker
  • libkdepim
  • libkleo
  • libkpgp
  • mailcommon
  • messagelist
  • messageviewer

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal