source: trunk/doc/html/qconststring.html@ 190

Last change on this file since 190 was 190, checked in by rudi, 14 years ago

reference documentation added

File size: 4.0 KB
Line 
1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
2<!-- /home/espenr/tmp/qt-3.3.8-espenr-2499/qt-x11-free-3.3.8/src/tools/qstring.cpp:6903 -->
3<html>
4<head>
5<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
6<title>QConstString Class</title>
7<style type="text/css"><!--
8fn { margin-left: 1cm; text-indent: -1cm; }
9a:link { color: #004faf; text-decoration: none }
10a:visited { color: #672967; text-decoration: none }
11body { background: #ffffff; color: black; }
12--></style>
13</head>
14<body>
15
16<table border="0" cellpadding="0" cellspacing="0" width="100%">
17<tr bgcolor="#E5E5E5">
18<td valign=center>
19 <a href="index.html">
20<font color="#004faf">Home</font></a>
21 | <a href="classes.html">
22<font color="#004faf">All&nbsp;Classes</font></a>
23 | <a href="mainclasses.html">
24<font color="#004faf">Main&nbsp;Classes</font></a>
25 | <a href="annotated.html">
26<font color="#004faf">Annotated</font></a>
27 | <a href="groups.html">
28<font color="#004faf">Grouped&nbsp;Classes</font></a>
29 | <a href="functions.html">
30<font color="#004faf">Functions</font></a>
31</td>
32<td align="right" valign="center"><img src="logo32.png" align="right" width="64" height="32" border="0"></td></tr></table><h1 align=center>QConstString Class Reference</h1>
33
34<p>The QConstString class provides string objects using constant Unicode data.
35<a href="#details">More...</a>
36<p>All the functions in this class are <a href="threads.html#reentrant">reentrant</a> when Qt is built with thread support.</p>
37<p><tt>#include &lt;<a href="qstring-h.html">qstring.h</a>&gt;</tt>
38<p><a href="qconststring-members.html">List of all member functions.</a>
39<h2>Public Members</h2>
40<ul>
41<li class=fn><a href="#QConstString"><b>QConstString</b></a> ( const&nbsp;QChar&nbsp;*&nbsp;unicode, uint&nbsp;length )</li>
42<li class=fn><a href="#~QConstString"><b>~QConstString</b></a> ()</li>
43<li class=fn>const QString &amp; <a href="#string"><b>string</b></a> () const</li>
44</ul>
45<hr><a name="details"></a><h2>Detailed Description</h2>
46
47
48
49
50The QConstString class provides string objects using constant Unicode data.
51<p> In order to minimize copying, highly optimized applications can
52use QConstString to provide a <a href="qstring.html">QString</a>-compatible object from
53existing Unicode data. It is then the programmer's responsibility
54to ensure that the Unicode data exists for the entire lifetime of
55the QConstString object.
56<p> A QConstString is created with the QConstString constructor. The
57string held by the object can be obtained by calling <a href="#string">string</a>().
58<p>See also <a href="text.html">Text Related Classes</a>.
59
60<hr><h2>Member Function Documentation</h2>
61<h3 class=fn><a name="QConstString"></a>QConstString::QConstString ( const&nbsp;<a href="qchar.html">QChar</a>&nbsp;*&nbsp;unicode, uint&nbsp;length )
62</h3>
63Constructs a QConstString that uses the first <em>length</em> Unicode
64characters in the array <em>unicode</em>. Any attempt to modify copies
65of the string will cause it to create a copy of the data, thus it
66remains forever unmodified.
67<p> The data in <em>unicode</em> is not copied. The caller must be able to
68guarantee that <em>unicode</em> will not be deleted or modified.
69
70<h3 class=fn><a name="~QConstString"></a>QConstString::~QConstString ()
71</h3>
72Destroys the QConstString, creating a copy of the data if other
73strings are still using it.
74
75<h3 class=fn>const&nbsp;<a href="qstring.html">QString</a>&nbsp;&amp; <a name="string"></a>QConstString::string () const
76</h3>
77
78<p> Returns a constant string referencing the data passed during
79construction.
80
81<!-- eof -->
82<hr><p>
83This file is part of the <a href="index.html">Qt toolkit</a>.
84Copyright &copy; 1995-2007
85<a href="http://www.trolltech.com/">Trolltech</a>. All Rights Reserved.<p><address><hr><div align=center>
86<table width=100% cellspacing=0 border=0><tr>
87<td>Copyright &copy; 2007
88<a href="troll.html">Trolltech</a><td align=center><a href="trademarks.html">Trademarks</a>
89<td align=right><div align=right>Qt 3.3.8</div>
90</table></div></address></body>
91</html>
Note: See TracBrowser for help on using the repository browser.