Sophie

Sophie

distrib > Mageia > 5 > i586 > media > core-release > by-pkgid > 50facae208d4a6f280e44a513b104320 > files > 1798

qt-mobility-doc-1.2.0-13.mga5.noarch.rpm

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.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" />
<!-- qversitresourcehandler.cpp -->
  <title>Qt Mobility 1.2: QVersitResourceHandler Class Reference</title>
  <link rel="stylesheet" type="text/css" href="style/offline.css" />
</head>
<body>
<div class="header" id="qtdocheader">
  <div class="content"> 
    <a href="index.html" class="qtref"><span>QtMobility Reference Documentation</span></a>
  </div>
  <div class="breadcrumb toolblock">
    <ul>
      <li class="first"><a href="index.html">Home</a></li>
      <!--  Breadcrumbs go here -->
<li><a href="modules.html">Modules</a></li>
<li><a href="qtversit.html">QtVersit</a></li>
<li>QVersitResourceHandler</li>
    </ul>
  </div>
</div>
<div class="content mainContent">
<div class="toc">
<h3><a name="toc">Contents</a></h3>
<ul>
<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">QVersitResourceHandler Class Reference</h1>
<!-- $$$QVersitResourceHandler-brief -->
<p>The QVersitResourceHandler class is an interface for clients wishing to implement custom behaviour for loading and saving files to disk when exporting and importing. <a href="#details">More...</a></p>
<!-- @@@QVersitResourceHandler -->
<pre class="cpp"> <span class="preprocessor">#include &lt;QVersitResourceHandler&gt;</span></pre><p><b>Inherited by: </b><a href="qversitdefaultresourcehandler.html">QVersitDefaultResourceHandler</a>.</p>
<p>This class was introduced in Qt Mobility 1.0.</p>
<ul>
<li><a href="qversitresourcehandler-members.html">List of all members, including inherited members</a></li>
</ul>
<a name="public-functions"></a>
<h2>Public Functions</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> virtual </td><td class="memItemRight bottomAlign"><b><a href="qversitresourcehandler.html#dtor.QVersitResourceHandler">~QVersitResourceHandler</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual bool </td><td class="memItemRight bottomAlign"><b><a href="qversitresourcehandler.html#loadResource">loadResource</a></b> ( const QString &amp; <i>location</i>, QByteArray * <i>contents</i>, QString * <i>mimeType</i> ) = 0</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual bool </td><td class="memItemRight bottomAlign"><b><a href="qversitresourcehandler.html#saveResource">saveResource</a></b> ( const QByteArray &amp; <i>contents</i>, const QVersitProperty &amp; <i>property</i>, QString * <i>location</i> ) = 0</td></tr>
</table>
<a name="details"></a>
<!-- $$$QVersitResourceHandler-description -->
<div class="descr">
<h2>Detailed Description</h2>
<p>The QVersitResourceHandler class is an interface for clients wishing to implement custom behaviour for loading and saving files to disk when exporting and importing.</p>
</div>
<p><b>See also </b><a href="qversitcontactimporter.html">QVersitContactImporter</a>, <a href="qversitcontactexporter.html">QVersitContactExporter</a>, and <a href="qversitdefaultresourcehandler.html">QVersitDefaultResourceHandler</a>.</p>
<!-- @@@QVersitResourceHandler -->
<div class="func">
<h2>Member Function Documentation</h2>
<!-- $$$~QVersitResourceHandler[overload1]$$$~QVersitResourceHandler -->
<h3 class="fn"><a name="dtor.QVersitResourceHandler"></a>QVersitResourceHandler::<span class="name">~QVersitResourceHandler</span> ()<tt> [virtual]</tt></h3>
<p>Frees any memory used by the handler.</p>
<!-- @@@~QVersitResourceHandler -->
<!-- $$$loadResource[overload1]$$$loadResourceconstQString&QByteArray*QString* -->
<h3 class="fn"><a name="loadResource"></a><span class="type">bool</span> QVersitResourceHandler::<span class="name">loadResource</span> ( const <span class="type"><a href="http://qt.nokia.com/doc/4.7/qstring.html">QString</a></span> &amp; <i>location</i>, <span class="type"><a href="http://qt.nokia.com/doc/4.7/qbytearray.html">QByteArray</a></span> * <i>contents</i>, <span class="type"><a href="http://qt.nokia.com/doc/4.7/qstring.html">QString</a></span> * <i>mimeType</i> )<tt> [pure virtual]</tt></h3>
<p>Loads a file from <i>location</i>. *<i>contents</i> is filled with the contents of the file and *<i>mimeType</i> is set to the MIME type that it is determined to be. Returns true on success, false on failure.</p>
<!-- @@@loadResource -->
<!-- $$$saveResource[overload1]$$$saveResourceconstQByteArray&constQVersitProperty&QString* -->
<h3 class="fn"><a name="saveResource"></a><span class="type">bool</span> QVersitResourceHandler::<span class="name">saveResource</span> ( const <span class="type"><a href="http://qt.nokia.com/doc/4.7/qbytearray.html">QByteArray</a></span> &amp; <i>contents</i>, const <span class="type"><a href="qversitproperty.html">QVersitProperty</a></span> &amp; <i>property</i>, <span class="type"><a href="http://qt.nokia.com/doc/4.7/qstring.html">QString</a></span> * <i>location</i> )<tt> [pure virtual]</tt></h3>
<p>Saves the binary data <i>contents</i> to a file on a persistent storage medium.</p>
<p><i>property</i> holds the <a href="qversitproperty.html">QVersitProperty</a> which is the context in which the binary is coming from. The <a href="qversitresourcehandler.html">QVersitResourceHandler</a> can use this, for example, to determine file extension it should choose. *<i>location</i> is filled with the contents of the file. Returns true on success, false on failure.</p>
<!-- @@@saveResource -->
</div>
  <div class="ft">
    <span></span>
  </div>
</div> 
<div class="footer">
  <p>
     <acronym title="Copyright">&copy;</acronym> 2008-2011 Nokia Corporation and/or its
     subsidiaries. Nokia, Qt and their respective logos are trademarks of Nokia Corporation 
     in Finland and/or other countries worldwide.</p>
  <p>
     All other trademarks are property of their respective owners. <a title="Privacy Policy"
     href="http://qt.nokia.com/about/privacy-policy">Privacy Policy</a></p>
  <br />
  <p>
    Licensees holding valid Qt Commercial licenses may use this document in accordance with the    Qt Commercial License Agreement provided with the Software or, alternatively, in accordance    with the terms contained in a written agreement between you and Nokia.</p>
  <p>
    Alternatively, this document may be used 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.</p>
</div>
</body>
</html>