/usr/share/qt5/doc/qtlocation/qplacecontent.html is in qtlocation5-doc-html 5.2.1-1ubuntu2.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 | <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en_US" lang="en_US">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<!-- qplacecontent.cpp -->
<title>QPlaceContent Class | QtLocation 5.2</title>
<link rel="stylesheet" type="text/css" href="style/offline.css" />
</head>
<body>
<div class="header" id="qtdocheader">
<div class="main">
<div class="main-rounded">
<div class="navigationbar">
<ul>
<li>Qt 5.2</li>
<li><a href="qtlocation-index.html">Qt Location</a></li>
<li><a href="qtlocation-module.html">C++ Classes</a></li>
<li>QPlaceContent</li>
<li id="buildversion">
Qt 5.2.1 Reference Documentation</li>
</ul>
</div>
</div>
<div class="content">
<div class="line">
<div class="content mainContent">
<div class="toc">
<h3><a name="toc">Contents</a></h3>
<ul>
<li class="level1"><a href="#public-types">Public Types</a></li>
<li class="level1"><a href="#public-functions">Public Functions</a></li>
<li class="level1"><a href="#details">Detailed Description</a></li>
</ul>
</div>
<h1 class="title">QPlaceContent Class</h1>
<!-- $$$QPlaceContent-brief -->
<p>The QPlaceContent class serves as the base class for rich content types. <a href="#details">More...</a></p>
<!-- @@@QPlaceContent -->
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> Header:</td><td class="memItemRight bottomAlign"> </b><tt><span class="preprocessor">#include <QPlaceContent></span>
</tt></td></tr><tr><td class="memItemLeft rightAlign topAlign"> qmake:</td><td class="memItemRight bottomAlign"> <tt>QT += location</tt></td></tr><tr><td class="memItemLeft rightAlign topAlign"> Since:</td><td class="memItemRight bottomAlign"> Qt Location 5.0</td></tr><tr><td class="memItemLeft rightAlign topAlign"> Inherited By:</td><td class="memItemRight bottomAlign"> <p><a href="qplaceeditorial.html">QPlaceEditorial</a>, <a href="qplaceimage.html">QPlaceImage</a>, and <a href="qplacereview.html">QPlaceReview</a>.</p>
</td></tr></table><ul>
<li><a href="qplacecontent-members.html">List of all members, including inherited members</a></li>
</ul>
<a name="public-types"></a>
<h2>Public Types</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> typedef </td><td class="memItemRight bottomAlign"><b><a href="qplacecontent.html#Collection-typedef">Collection</a></b></td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> enum </td><td class="memItemRight bottomAlign"><b><a href="qplacecontent.html#Type-enum">Type</a></b> { NoType, ImageType, ReviewType, EditorialType }</td></tr>
</table>
<a name="public-functions"></a>
<h2>Public Functions</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="qplacecontent.html#QPlaceContent">QPlaceContent</a></b>()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="qplacecontent.html#QPlaceContent-2">QPlaceContent</a></b>(const QPlaceContent &<i> other</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual </td><td class="memItemRight bottomAlign"><b><a href="qplacecontent.html#dtor.QPlaceContent">~QPlaceContent</a></b>()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QString </td><td class="memItemRight bottomAlign"><b><a href="qplacecontent.html#attribution">attribution</a></b>() const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qplacecontent.html#setAttribution">setAttribution</a></b>(const QString &<i> attribution</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qplacecontent.html#setSupplier">setSupplier</a></b>(const QPlaceSupplier &<i> supplier</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qplacecontent.html#setUser">setUser</a></b>(const QPlaceUser &<i> user</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QPlaceSupplier </td><td class="memItemRight bottomAlign"><b><a href="qplacecontent.html#supplier">supplier</a></b>() const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QPlaceContent::Type </td><td class="memItemRight bottomAlign"><b><a href="qplacecontent.html#type">type</a></b>() const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QPlaceUser </td><td class="memItemRight bottomAlign"><b><a href="qplacecontent.html#user">user</a></b>() const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qplacecontent.html#operator-not-eq">operator!=</a></b>(const QPlaceContent &<i> other</i>) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QPlaceContent & </td><td class="memItemRight bottomAlign"><b><a href="qplacecontent.html#operator-eq">operator=</a></b>(const QPlaceContent &<i> other</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qplacecontent.html#operator-eq-eq">operator==</a></b>(const QPlaceContent &<i> other</i>) const</td></tr>
</table>
<a name="details"></a>
<!-- $$$QPlaceContent-description -->
<div class="descr">
<h2>Detailed Description</h2>
<p>The QPlaceContent class serves as the base class for rich content types.</p>
<p>Rich content such as <a href="qplaceimage.html">images</a>, <a href="qplacereview.html">reviews</a> and <a href="qplaceeditorial.html">editorials</a> inherit from the QPlaceContent class which contains common properties such as an attribution string and content contributor, which may take the form of a <a href="qplaceuser.html">user</a> and/or <a href="qplacesupplier.html">supplier</a>. It is possible that a user from a supplier is contributing content, hence both fields could be filled in simultaneously.</p>
<p><b>Note:</b> Some providers may <i>require</i> that the attribution string be displayed to the user whenever a piece of content is viewed.</p>
<p>Conversion between QPlaceContent and it's subclasses can be easily performed without casting. Due to the way it has been implemented, object slicing is not an issue, the following code is valid:</p>
<pre class="cpp"><span class="type"><a href="qplaceimage.html">QPlaceImage</a></span> image;
image<span class="operator">.</span>setUrl(<span class="type">QUrl</span>(<span class="string">"www.example.com"</span>));
<span class="type">QPlaceContent</span> content <span class="operator">=</span> image;
<span class="type"><a href="qplaceimage.html">QPlaceImage</a></span> image2;
image2 <span class="operator">=</span> content;
qDebug() <span class="operator"><</span><span class="operator"><</span> image2<span class="operator">.</span>url(); <span class="comment">//image2.url() == "www.example.com"</span></pre>
<p>The rich content of a place is typically made available as paginated items. The ability to convert between QPlaceContent and it's subclasses means that code which handles the mechanics of paging can be easily shared for each of the sub types.</p>
<p>At present the QPlaceContent class is not extensible by 3rd parties.</p>
<p>Note: The Places API considers content objects to be 'retrieve-only' objects. Submission of content to a provider is not a supported use case.</p>
</div>
<p><b>See also </b><a href="qplaceimage.html">QPlaceImage</a>, <a href="qplacereview.html">QPlaceReview</a>, and <a href="qplaceeditorial.html">QPlaceEditorial</a>.</p>
<!-- @@@QPlaceContent -->
<div class="types">
<h2>Member Type Documentation</h2>
<!-- $$$Collection -->
<h3 class="fn"><a name="Collection-typedef"></a>typedef QPlaceContent::<span class="name">Collection</span></h3>
<p>Synonym for QMap<int, <a href="qplacecontent.html">QPlaceContent</a>>. The key of the map is an <tt>int</tt> representing the index of the content. The value is the content object itself.</p>
<p>The <tt>Collection</tt> is intended to be a container where content items, that have been retrieved as pages, can be stored. This enables a developer to skip pages, for example indexes 0-9 may be stored in the collection, if the user skips to indexes 80-99, these can be stored in the collection as well.</p>
<!-- @@@Collection -->
<!-- $$$Type$$$NoType$$$ImageType$$$ReviewType$$$EditorialType -->
<h3 class="fn"><a name="Type-enum"></a>enum QPlaceContent::<span class="name">Type</span></h3>
<p>Defines the type of content.</p>
<table class="valuelist"><tr valign="top" class="odd"><th class="tblConst">Constant</th><th class="tblval">Value</th><th class="tbldscr">Description</th></tr>
<tr><td class="topAlign"><tt>QPlaceContent::NoType</tt></td><td class="topAlign"><tt>0</tt></td><td class="topAlign">The content object is default constructed, any other content type may be assigned to this content object.</td></tr>
<tr><td class="topAlign"><tt>QPlaceContent::ImageType</tt></td><td class="topAlign"><tt>1</tt></td><td class="topAlign">The content object is an image.</td></tr>
<tr><td class="topAlign"><tt>QPlaceContent::ReviewType</tt></td><td class="topAlign"><tt>2</tt></td><td class="topAlign">The content object is a review.</td></tr>
<tr><td class="topAlign"><tt>QPlaceContent::EditorialType</tt></td><td class="topAlign"><tt>3</tt></td><td class="topAlign">The content object is an editorial</td></tr>
</table>
<!-- @@@Type -->
</div>
<div class="func">
<h2>Member Function Documentation</h2>
<!-- $$$QPlaceContent[overload1]$$$QPlaceContent -->
<h3 class="fn"><a name="QPlaceContent"></a>QPlaceContent::<span class="name">QPlaceContent</span>()</h3>
<p>Constructs an default content object which has no type.</p>
<!-- @@@QPlaceContent -->
<!-- $$$QPlaceContent$$$QPlaceContentconstQPlaceContent& -->
<h3 class="fn"><a name="QPlaceContent-2"></a>QPlaceContent::<span class="name">QPlaceContent</span>(const <span class="type">QPlaceContent</span> &<i> other</i>)</h3>
<p>Constructs a new copy of <i>other</i>.</p>
<!-- @@@QPlaceContent -->
<!-- $$$~QPlaceContent[overload1]$$$~QPlaceContent -->
<h3 class="fn"><a name="dtor.QPlaceContent"></a>QPlaceContent::<span class="name">~QPlaceContent</span>()<tt> [virtual]</tt></h3>
<p>Destroys the content object.</p>
<!-- @@@~QPlaceContent -->
<!-- $$$attribution[overload1]$$$attribution -->
<h3 class="fn"><a name="attribution"></a><span class="type">QString</span> QPlaceContent::<span class="name">attribution</span>() const</h3>
<p>Returns a rich text attribution string.</p>
<p><b>Note</b>: Some providers may require that the attribution of a particular content item always be displayed when the content item is shown.</p>
<p><b>See also </b><a href="qplacecontent.html#setAttribution">setAttribution</a>().</p>
<!-- @@@attribution -->
<!-- $$$setAttribution[overload1]$$$setAttributionconstQString& -->
<h3 class="fn"><a name="setAttribution"></a><span class="type">void</span> QPlaceContent::<span class="name">setAttribution</span>(const <span class="type">QString</span> &<i> attribution</i>)</h3>
<p>Sets a rich text <i>attribution</i> string for this content item.</p>
<p><b>See also </b><a href="qplacecontent.html#attribution">attribution</a>().</p>
<!-- @@@setAttribution -->
<!-- $$$setSupplier[overload1]$$$setSupplierconstQPlaceSupplier& -->
<h3 class="fn"><a name="setSupplier"></a><span class="type">void</span> QPlaceContent::<span class="name">setSupplier</span>(const <span class="type"><a href="qplacesupplier.html">QPlaceSupplier</a></span> &<i> supplier</i>)</h3>
<p>Sets the <i>supplier</i> of the content.</p>
<p><b>See also </b><a href="qplacecontent.html#supplier">supplier</a>().</p>
<!-- @@@setSupplier -->
<!-- $$$setUser[overload1]$$$setUserconstQPlaceUser& -->
<h3 class="fn"><a name="setUser"></a><span class="type">void</span> QPlaceContent::<span class="name">setUser</span>(const <span class="type"><a href="qplaceuser.html">QPlaceUser</a></span> &<i> user</i>)</h3>
<p>Sets the <i>user</i> who contributed this content.</p>
<p><b>See also </b><a href="qplacecontent.html#user">user</a>().</p>
<!-- @@@setUser -->
<!-- $$$supplier[overload1]$$$supplier -->
<h3 class="fn"><a name="supplier"></a><span class="type"><a href="qplacesupplier.html">QPlaceSupplier</a></span> QPlaceContent::<span class="name">supplier</span>() const</h3>
<p>Returns the supplier who contributed this content.</p>
<p><b>See also </b><a href="qplacecontent.html#setSupplier">setSupplier</a>().</p>
<!-- @@@supplier -->
<!-- $$$type[overload1]$$$type -->
<h3 class="fn"><a name="type"></a><span class="type"><a href="qplacecontent.html#Type-enum">QPlaceContent::Type</a></span> QPlaceContent::<span class="name">type</span>() const</h3>
<p>Returns the content type.</p>
<!-- @@@type -->
<!-- $$$user[overload1]$$$user -->
<h3 class="fn"><a name="user"></a><span class="type"><a href="qplaceuser.html">QPlaceUser</a></span> QPlaceContent::<span class="name">user</span>() const</h3>
<p>Returns the user who contributed this content.</p>
<p><b>See also </b><a href="qplacecontent.html#setUser">setUser</a>().</p>
<!-- @@@user -->
<!-- $$$operator!=[overload1]$$$operator!=constQPlaceContent& -->
<h3 class="fn"><a name="operator-not-eq"></a><span class="type">bool</span> QPlaceContent::<span class="name">operator!=</span>(const <span class="type">QPlaceContent</span> &<i> other</i>) const</h3>
<p>Returns true if this content object is not equivalent to <i>other</i>, otherwise returns false.</p>
<!-- @@@operator!= -->
<!-- $$$operator=[overload1]$$$operator=constQPlaceContent& -->
<h3 class="fn"><a name="operator-eq"></a><span class="type">QPlaceContent</span> & QPlaceContent::<span class="name">operator=</span>(const <span class="type">QPlaceContent</span> &<i> other</i>)</h3>
<p>Assigns the <i>other</i> content object to this and returns a reference to this content object.</p>
<!-- @@@operator= -->
<!-- $$$operator==[overload1]$$$operator==constQPlaceContent& -->
<h3 class="fn"><a name="operator-eq-eq"></a><span class="type">bool</span> QPlaceContent::<span class="name">operator==</span>(const <span class="type">QPlaceContent</span> &<i> other</i>) const</h3>
<p>Returns true if this content object is equivalent to <i>other</i>, otherwise returns false.</p>
<!-- @@@operator== -->
</div>
</div>
</div>
</div>
</div>
</div>
<div class="footer">
<p>
<acronym title="Copyright">©</acronym> 2013 Digia Plc and/or its
subsidiaries. Documentation contributions included herein are the copyrights of
their respective owners.<br> The documentation provided herein is licensed under the terms of the <a href="http://www.gnu.org/licenses/fdl.html">GNU Free Documentation License version 1.3</a> as published by the Free Software Foundation.<br> Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide. All other trademarks are property
of their respective owners. </p>
</div>
</body>
</html>
|