<?xml version="1.0" encoding="iso-8859-1"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <!-- qwebhistory.cpp --> <head> <title>Qt 4.6: QWebHistoryItem Class Reference</title> <link href="classic.css" rel="stylesheet" type="text/css" /> </head> <body> <a name="//apple_ref/cpp/cl//QWebHistoryItem"></a> <table border="0" cellpadding="0" cellspacing="0" width="100%"> <tr> <td align="left" valign="top" width="32"><a href="http://qt.nokia.com/"><img src="images/qt-logo.png" align="left" border="0" /></a></td> <td width="1"> </td><td class="postheader" valign="center"><a href="index.html"><font color="#004faf">Home</font></a> · <a href="classes.html"><font color="#004faf">All Classes</font></a> · <a href="functions.html"><font color="#004faf">All Functions</font></a> · <a href="overviews.html"><font color="#004faf">Overviews</font></a></td></tr></table><h1 class="title">QWebHistoryItem Class Reference<br /><span class="small-subtitle">[<a href="qtwebkit.html">QtWebKit</a> module]</span> </h1> <p>The QWebHistoryItem class represents one item in the history of a <a href="qwebpage.html">QWebPage</a> <a href="#details">More...</a></p> <pre> #include <QWebHistoryItem></pre><p><b>This class is not part of the Qt GUI Framework Edition.</b></p> <p>This class was introduced in Qt 4.4.</p> <ul> <li><a href="qwebhistoryitem-members.html">List of all members, including inherited members</a></li> </ul> <hr /> <a name="public-functions"></a> <h2>Public Functions</h2> <table class="alignedsummary" border="0" cellpadding="0" cellspacing="0" width="100%"> <tr><td class="memItemLeft" align="right" valign="top"></td><td class="memItemRight" valign="bottom"><b><a href="qwebhistoryitem.html#QWebHistoryItem">QWebHistoryItem</a></b> ( const QWebHistoryItem & <i>other</i> )</td></tr> <tr><td class="memItemLeft" align="right" valign="top"></td><td class="memItemRight" valign="bottom"><b><a href="qwebhistoryitem.html#dtor.QWebHistoryItem">~QWebHistoryItem</a></b> ()</td></tr> <tr><td class="memItemLeft" align="right" valign="top">QIcon </td><td class="memItemRight" valign="bottom"><b><a href="qwebhistoryitem.html#icon">icon</a></b> () const</td></tr> <tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><b><a href="qwebhistoryitem.html#isValid">isValid</a></b> () const</td></tr> <tr><td class="memItemLeft" align="right" valign="top">QDateTime </td><td class="memItemRight" valign="bottom"><b><a href="qwebhistoryitem.html#lastVisited">lastVisited</a></b> () const</td></tr> <tr><td class="memItemLeft" align="right" valign="top">QUrl </td><td class="memItemRight" valign="bottom"><b><a href="qwebhistoryitem.html#originalUrl">originalUrl</a></b> () const</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><b><a href="qwebhistoryitem.html#setUserData">setUserData</a></b> ( const QVariant & <i>userData</i> )</td></tr> <tr><td class="memItemLeft" align="right" valign="top">QString </td><td class="memItemRight" valign="bottom"><b><a href="qwebhistoryitem.html#title">title</a></b> () const</td></tr> <tr><td class="memItemLeft" align="right" valign="top">QUrl </td><td class="memItemRight" valign="bottom"><b><a href="qwebhistoryitem.html#url">url</a></b> () const</td></tr> <tr><td class="memItemLeft" align="right" valign="top">QVariant </td><td class="memItemRight" valign="bottom"><b><a href="qwebhistoryitem.html#userData">userData</a></b> () const</td></tr> <tr><td class="memItemLeft" align="right" valign="top">QWebHistoryItem & </td><td class="memItemRight" valign="bottom"><b><a href="qwebhistoryitem.html#operator-eq">operator=</a></b> ( const QWebHistoryItem & <i>other</i> )</td></tr> </table> <a name="details"></a> <hr /> <h2>Detailed Description</h2> <p>The QWebHistoryItem class represents one item in the history of a <a href="qwebpage.html">QWebPage</a></p> <p>Each QWebHistoryItem instance represents an entry in the history stack of a Web page, containing information about the page, its location, and when it was last visited.</p> <p>The following table shows the properties of the page held by the history item, and the functions used to access them.</p> <p><table class="generic" align="center" cellpadding="2" cellspacing="1" border="0"> <thead><tr valign="top" class="qt-style"><th>Function</th><th>Description</th></tr></thead> <tr valign="top" class="odd"><td><a href="qwebhistoryitem.html#title">title</a>()</td><td>The page title.</td></tr> <tr valign="top" class="even"><td><a href="qwebhistoryitem.html#url">url</a>()</td><td>The location of the page.</td></tr> <tr valign="top" class="odd"><td><a href="qwebhistoryitem.html#originalUrl">originalUrl</a>()</td><td>The URL used to access the page.</td></tr> <tr valign="top" class="even"><td><a href="qwebhistoryitem.html#lastVisited">lastVisited</a>()</td><td>The date and time of the user's last visit to the page.</td></tr> <tr valign="top" class="odd"><td><a href="qwebhistoryitem.html#icon">icon</a>()</td><td>The icon associated with the page that was provided by the server.</td></tr> <tr valign="top" class="even"><td><a href="qwebhistoryitem.html#userData">userData</a>()</td><td>The user specific data that was stored with the history item.</td></tr> </table></p> <p><b>Note:</b> QWebHistoryItem objects are value based, but <i>explicitly shared</i>. Changing a QWebHistoryItem instance by calling <a href="qwebhistoryitem.html#setUserData">setUserData</a>() will change all copies of that instance.</p> <p>See also <a href="qwebhistory.html">QWebHistory</a>, <a href="qwebpage.html#history">QWebPage::history</a>(), and <a href="qwebhistoryinterface.html">QWebHistoryInterface</a>.</p> <hr /> <h2>Member Function Documentation</h2> <a name="//apple_ref/cpp/instm/QWebHistoryItem/QWebHistoryItem"></a> <h3 class="fn"><a name="QWebHistoryItem"></a>QWebHistoryItem::QWebHistoryItem ( const QWebHistoryItem & <i>other</i> )</h3> <p>Constructs a history item from <i>other</i>. The new item and <i>other</i> will share their data, and modifying either this item or <i>other</i> will modify both instances.</p> <a name="//apple_ref/cpp/instm/QWebHistoryItem/~QWebHistoryItem"></a> <h3 class="fn"><a name="dtor.QWebHistoryItem"></a>QWebHistoryItem::~QWebHistoryItem ()</h3> <p>Destroys the history item.</p> <a name="//apple_ref/cpp/instm/QWebHistoryItem/icon"></a> <h3 class="fn"><a name="icon"></a><a href="qicon.html">QIcon</a> QWebHistoryItem::icon () const</h3> <p>Returns the icon associated with the history item.</p> <p>See also <a href="qwebhistoryitem.html#title">title</a>(), <a href="qwebhistoryitem.html#url">url</a>(), and <a href="qwebhistoryitem.html#lastVisited">lastVisited</a>().</p> <a name="//apple_ref/cpp/instm/QWebHistoryItem/isValid"></a> <h3 class="fn"><a name="isValid"></a>bool QWebHistoryItem::isValid () const</h3> <p>Returns whether this is a valid history item.</p> <p>This function was introduced in Qt 4.5.</p> <a name="//apple_ref/cpp/instm/QWebHistoryItem/lastVisited"></a> <h3 class="fn"><a name="lastVisited"></a><a href="qdatetime.html">QDateTime</a> QWebHistoryItem::lastVisited () const</h3> <p>Returns the date and time that the page associated with the item was last visited.</p> <p>See also <a href="qwebhistoryitem.html#title">title</a>(), <a href="qwebhistoryitem.html#icon">icon</a>(), and <a href="qwebhistoryitem.html#url">url</a>().</p> <a name="//apple_ref/cpp/instm/QWebHistoryItem/originalUrl"></a> <h3 class="fn"><a name="originalUrl"></a><a href="qurl.html">QUrl</a> QWebHistoryItem::originalUrl () const</h3> <p>Returns the original URL associated with the history item.</p> <p>See also <a href="qwebhistoryitem.html#url">url</a>().</p> <a name="//apple_ref/cpp/instm/QWebHistoryItem/setUserData"></a> <h3 class="fn"><a name="setUserData"></a>void QWebHistoryItem::setUserData ( const <a href="qvariant.html">QVariant</a> & <i>userData</i> )</h3> <p>Stores user specific data <i>userData</i> with the history item.</p> <p><b>Note:</b> All copies of this item will be modified.</p> <p>This function was introduced in Qt 4.5.</p> <p>See also <a href="qwebhistoryitem.html#userData">userData</a>().</p> <a name="//apple_ref/cpp/instm/QWebHistoryItem/title"></a> <h3 class="fn"><a name="title"></a><a href="qstring.html">QString</a> QWebHistoryItem::title () const</h3> <p>Returns the title of the page associated with the history item.</p> <p>See also <a href="qwebhistoryitem.html#icon">icon</a>(), <a href="qwebhistoryitem.html#url">url</a>(), and <a href="qwebhistoryitem.html#lastVisited">lastVisited</a>().</p> <a name="//apple_ref/cpp/instm/QWebHistoryItem/url"></a> <h3 class="fn"><a name="url"></a><a href="qurl.html">QUrl</a> QWebHistoryItem::url () const</h3> <p>Returns the URL associated with the history item.</p> <p>See also <a href="qwebhistoryitem.html#originalUrl">originalUrl</a>(), <a href="qwebhistoryitem.html#title">title</a>(), and <a href="qwebhistoryitem.html#lastVisited">lastVisited</a>().</p> <a name="//apple_ref/cpp/instm/QWebHistoryItem/userData"></a> <h3 class="fn"><a name="userData"></a><a href="qvariant.html">QVariant</a> QWebHistoryItem::userData () const</h3> <p>Returns the user specific data that was stored with the history item.</p> <p>This function was introduced in Qt 4.5.</p> <p>See also <a href="qwebhistoryitem.html#setUserData">setUserData</a>().</p> <a name="//apple_ref/cpp/instm/QWebHistoryItem/operator="></a> <h3 class="fn"><a name="operator-eq"></a>QWebHistoryItem & QWebHistoryItem::operator= ( const QWebHistoryItem & <i>other</i> )</h3> <p>Assigns the <i>other</i> history item to this. This item and <i>other</i> will share their data, and modifying either this item or <i>other</i> will modify both instances.</p> <p /><address><hr /><div align="center"> <table width="100%" cellspacing="0" border="0"><tr class="address"> <td width="40%" align="left">Copyright © 2010 Nokia Corporation and/or its subsidiary(-ies)</td> <td width="20%" align="center"><a href="trademarks.html">Trademarks</a></td> <td width="40%" align="right"><div align="right">Qt 4.6.3</div></td> </tr></table></div></address></body> </html>