Sophie

Sophie

distrib > Mandriva > current > i586 > media > main-updates > by-pkgid > f51238514e2abe817779ad2fe01b0759 > files > 454

icu-doc-4.4-2.1mdv2010.2.i586.rpm

<!-- This comment will put IE 6, 7 and 8 in quirks mode -->
<!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">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<title>ICU 4.4: rep.h Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javaScript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css"/>
</head>
<body onload='searchBox.OnSelectItem(0);'>
<!-- Generated by Doxygen 1.6.1 -->
<script type="text/javascript"><!--
var searchBox = new SearchBox("searchBox", "search",false,'Search');
--></script>
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="pages.html"><span>Related&nbsp;Pages</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <img id="MSearchSelect" src="search/search.png"
             onmouseover="return searchBox.OnSearchSelectShow()"
             onmouseout="return searchBox.OnSearchSelectHide()"
             alt=""/>
        <input type="text" id="MSearchField" value="Search" accesskey="S"
             onfocus="searchBox.OnSearchFieldFocus(true)" 
             onblur="searchBox.OnSearchFieldFocus(false)" 
             onkeyup="searchBox.OnSearchFieldChange(event)"/>
        <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
        </div>
      </li>
    </ul>
  </div>
  <div class="tabs">
    <ul>
      <li><a href="files.html"><span>File&nbsp;List</span></a></li>
      <li><a href="globals.html"><span>Globals</span></a></li>
    </ul>
  </div>
<h1>rep.h</h1><a href="rep_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
<a name="l00002"></a>00002 <span class="comment">**************************************************************************</span>
<a name="l00003"></a>00003 <span class="comment">* Copyright (C) 1999-2005, International Business Machines Corporation and</span>
<a name="l00004"></a>00004 <span class="comment">* others. All Rights Reserved.</span>
<a name="l00005"></a>00005 <span class="comment">**************************************************************************</span>
<a name="l00006"></a>00006 <span class="comment">*   Date        Name        Description</span>
<a name="l00007"></a>00007 <span class="comment">*   11/17/99    aliu        Creation.  Ported from java.  Modified to</span>
<a name="l00008"></a>00008 <span class="comment">*                           match current UnicodeString API.  Forced</span>
<a name="l00009"></a>00009 <span class="comment">*                           to use name &quot;handleReplaceBetween&quot; because</span>
<a name="l00010"></a>00010 <span class="comment">*                           of existing methods in UnicodeString.</span>
<a name="l00011"></a>00011 <span class="comment">**************************************************************************</span>
<a name="l00012"></a>00012 <span class="comment">*/</span>
<a name="l00013"></a>00013 
<a name="l00014"></a>00014 <span class="preprocessor">#ifndef REP_H</span>
<a name="l00015"></a>00015 <span class="preprocessor"></span><span class="preprocessor">#define REP_H</span>
<a name="l00016"></a>00016 <span class="preprocessor"></span>
<a name="l00017"></a>00017 <span class="preprocessor">#include &quot;<a class="code" href="uobject_8h.html" title="C++ API: Common ICU base class UObject.">unicode/uobject.h</a>&quot;</span>
<a name="l00018"></a>00018 
<a name="l00024"></a>00024 <a class="code" href="uversion_8h.html#a7d9374e037299886d4192b763b4c5e8b" title="This is used to begin a declaration of a public ICU C++ API.">U_NAMESPACE_BEGIN</a>
<a name="l00025"></a>00025 
<a name="l00026"></a>00026 <span class="keyword">class </span><a class="code" href="classUnicodeString.html" title="UnicodeString is a string class that stores Unicode characters directly and provides...">UnicodeString</a>;
<a name="l00027"></a>00027 
<a name="l00071"></a><a class="code" href="classReplaceable.html">00071</a> <span class="keyword">class </span><a class="code" href="utypes_8h.html#a559955ec3bc692657c5d8b1c6de8e334" title="Set to export library symbols from inside the common library, and to import them...">U_COMMON_API</a> <a class="code" href="classReplaceable.html" title="Replaceable is an abstract base class representing a string of characters that supports...">Replaceable</a> : <span class="keyword">public</span> <a class="code" href="classUObject.html" title="UObject is the common ICU &amp;quot;boilerplate&amp;quot; class.">UObject</a> {
<a name="l00072"></a>00072 
<a name="l00073"></a>00073 <span class="keyword">public</span>:
<a name="l00078"></a>00078     <span class="keyword">virtual</span> ~<a class="code" href="classReplaceable.html" title="Replaceable is an abstract base class representing a string of characters that supports...">Replaceable</a>();
<a name="l00079"></a>00079 
<a name="l00085"></a>00085     <span class="keyword">inline</span> int32_t length() <span class="keyword">const</span>;
<a name="l00086"></a>00086 
<a name="l00094"></a>00094     <span class="keyword">inline</span> <a class="code" href="umachine_8h.html#a6bb9fad572d65b305324ef288165e2ac" title="Define UChar to be wchar_t if that is 16 bits wide; always assumed to be unsigned...">UChar</a> charAt(int32_t offset) <span class="keyword">const</span>;
<a name="l00095"></a>00095 
<a name="l00108"></a>00108     <span class="keyword">inline</span> <a class="code" href="umachine_8h.html#a09fff5c3b5a5b015324dc3ec3cf92809" title="Define UChar32 as a type for single Unicode code points.">UChar32</a> char32At(int32_t offset) <span class="keyword">const</span>;
<a name="l00109"></a>00109 
<a name="l00120"></a>00120     <span class="keyword">virtual</span> <span class="keywordtype">void</span> extractBetween(int32_t start,
<a name="l00121"></a>00121                                 int32_t limit,
<a name="l00122"></a>00122                                 <a class="code" href="classUnicodeString.html" title="UnicodeString is a string class that stores Unicode characters directly and provides...">UnicodeString</a>&amp; target) <span class="keyword">const</span> = 0;
<a name="l00123"></a>00123 
<a name="l00144"></a>00144     <span class="keyword">virtual</span> <span class="keywordtype">void</span> handleReplaceBetween(int32_t start,
<a name="l00145"></a>00145                                       int32_t limit,
<a name="l00146"></a>00146                                       <span class="keyword">const</span> <a class="code" href="classUnicodeString.html" title="UnicodeString is a string class that stores Unicode characters directly and provides...">UnicodeString</a>&amp; text) = 0;
<a name="l00147"></a>00147     <span class="comment">// Note: All other methods in this class take the names of</span>
<a name="l00148"></a>00148     <span class="comment">// existing UnicodeString methods.  This method is the exception.</span>
<a name="l00149"></a>00149     <span class="comment">// It is named differently because all replace methods of</span>
<a name="l00150"></a>00150     <span class="comment">// UnicodeString return a UnicodeString&amp;.  The &apos;between&apos; is</span>
<a name="l00151"></a>00151     <span class="comment">// required in order to conform to the UnicodeString naming</span>
<a name="l00152"></a>00152     <span class="comment">// convention; API taking start/length are named &lt;operation&gt;, and</span>
<a name="l00153"></a>00153     <span class="comment">// those taking start/limit are named &lt;operationBetween&gt;.  The</span>
<a name="l00154"></a>00154     <span class="comment">// &apos;handle&apos; is added because &apos;replaceBetween&apos; and</span>
<a name="l00155"></a>00155     <span class="comment">// &apos;doReplaceBetween&apos; are already taken.</span>
<a name="l00156"></a>00156 
<a name="l00172"></a>00172     <span class="keyword">virtual</span> <span class="keywordtype">void</span> copy(int32_t start, int32_t limit, int32_t dest) = 0;
<a name="l00173"></a>00173 
<a name="l00183"></a>00183     <span class="keyword">virtual</span> <a class="code" href="umachine_8h.html#a349ef00011f20ccd1d3b424445681aa5" title="The ICU boolean type.">UBool</a> hasMetaData() <span class="keyword">const</span>;
<a name="l00184"></a>00184 
<a name="l00200"></a>00200     <span class="keyword">virtual</span> <a class="code" href="classReplaceable.html" title="Replaceable is an abstract base class representing a string of characters that supports...">Replaceable</a> *clone() <span class="keyword">const</span>;
<a name="l00201"></a>00201 
<a name="l00202"></a>00202 <span class="keyword">protected</span>:
<a name="l00203"></a>00203 
<a name="l00208"></a>00208     <a class="code" href="classReplaceable.html" title="Replaceable is an abstract base class representing a string of characters that supports...">Replaceable</a>();
<a name="l00209"></a>00209 
<a name="l00210"></a>00210     <span class="comment">/*</span>
<a name="l00211"></a>00211 <span class="comment">     * Assignment operator not declared. The compiler will provide one</span>
<a name="l00212"></a>00212 <span class="comment">     * which does nothing since this class does not contain any data members.</span>
<a name="l00213"></a>00213 <span class="comment">     * API/code coverage may show the assignment operator as present and</span>
<a name="l00214"></a>00214 <span class="comment">     * untested - ignore.</span>
<a name="l00215"></a>00215 <span class="comment">     * Subclasses need this assignment operator if they use compiler-provided</span>
<a name="l00216"></a>00216 <span class="comment">     * assignment operators of their own. An alternative to not declaring one</span>
<a name="l00217"></a>00217 <span class="comment">     * here would be to declare and empty-implement a protected or public one.</span>
<a name="l00218"></a>00218 <span class="comment">    Replaceable &amp;Replaceable::operator=(const Replaceable &amp;);</span>
<a name="l00219"></a>00219 <span class="comment">     */</span>
<a name="l00220"></a>00220 
<a name="l00225"></a>00225     <span class="keyword">virtual</span> int32_t getLength() <span class="keyword">const</span> = 0;
<a name="l00226"></a>00226 
<a name="l00231"></a>00231     <span class="keyword">virtual</span> <a class="code" href="umachine_8h.html#a6bb9fad572d65b305324ef288165e2ac" title="Define UChar to be wchar_t if that is 16 bits wide; always assumed to be unsigned...">UChar</a> getCharAt(int32_t offset) <span class="keyword">const</span> = 0;
<a name="l00232"></a>00232 
<a name="l00237"></a>00237     <span class="keyword">virtual</span> <a class="code" href="umachine_8h.html#a09fff5c3b5a5b015324dc3ec3cf92809" title="Define UChar32 as a type for single Unicode code points.">UChar32</a> getChar32At(int32_t offset) <span class="keyword">const</span> = 0;
<a name="l00238"></a>00238 };
<a name="l00239"></a>00239 
<a name="l00240"></a>00240 <span class="keyword">inline</span> int32_t
<a name="l00241"></a><a class="code" href="classReplaceable.html#a81c2af838cfaf3c2a0d46b7fa727e8d0">00241</a> <a class="code" href="classReplaceable.html#a81c2af838cfaf3c2a0d46b7fa727e8d0" title="Returns the number of 16-bit code units in the text.">Replaceable::length</a>()<span class="keyword"> const </span>{
<a name="l00242"></a>00242     <span class="keywordflow">return</span> <a class="code" href="classReplaceable.html#aaa70d54cdfecf5e6a0a86566c8f75809" title="Virtual version of length().">getLength</a>();
<a name="l00243"></a>00243 }
<a name="l00244"></a>00244 
<a name="l00245"></a>00245 <span class="keyword">inline</span> <a class="code" href="umachine_8h.html#a6bb9fad572d65b305324ef288165e2ac" title="Define UChar to be wchar_t if that is 16 bits wide; always assumed to be unsigned...">UChar</a>
<a name="l00246"></a><a class="code" href="classReplaceable.html#a78909dd61599c6f2d8af7a9d3bf5dd0f">00246</a> <a class="code" href="classReplaceable.html#a78909dd61599c6f2d8af7a9d3bf5dd0f" title="Returns the 16-bit code unit at the given offset into the text.">Replaceable::charAt</a>(int32_t offset)<span class="keyword"> const </span>{
<a name="l00247"></a>00247     <span class="keywordflow">return</span> <a class="code" href="classReplaceable.html#a5cb36727170bbcc883a0c5846a6c4484" title="Virtual version of charAt().">getCharAt</a>(offset);
<a name="l00248"></a>00248 }
<a name="l00249"></a>00249 
<a name="l00250"></a>00250 <span class="keyword">inline</span> <a class="code" href="umachine_8h.html#a09fff5c3b5a5b015324dc3ec3cf92809" title="Define UChar32 as a type for single Unicode code points.">UChar32</a>
<a name="l00251"></a><a class="code" href="classReplaceable.html#ac7e972cbbe070b5fb1d0f824d2badb2c">00251</a> <a class="code" href="classReplaceable.html#ac7e972cbbe070b5fb1d0f824d2badb2c" title="Returns the 32-bit code point at the given 16-bit offset into the text.">Replaceable::char32At</a>(int32_t offset)<span class="keyword"> const </span>{
<a name="l00252"></a>00252     <span class="keywordflow">return</span> <a class="code" href="classReplaceable.html#a6305704f7ac09b06c85fd7698f7ac384" title="Virtual version of char32At().">getChar32At</a>(offset);
<a name="l00253"></a>00253 }
<a name="l00254"></a>00254 
<a name="l00255"></a>00255 <span class="comment">// There is no rep.cpp, see unistr.cpp for Replaceable function implementations.</span>
<a name="l00256"></a>00256 
<a name="l00257"></a>00257 <a class="code" href="uversion_8h.html#a3da1f00f3b02976ac53c014a3e4c0933" title="This is used to end a declaration of a public ICU C++ API.">U_NAMESPACE_END</a>
<a name="l00258"></a>00258 
<a name="l00259"></a>00259 <span class="preprocessor">#endif</span>
</pre></div></div>
<!--- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&nbsp;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&nbsp;</span>Data Structures</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&nbsp;</span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&nbsp;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&nbsp;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&nbsp;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&nbsp;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&nbsp;</span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark">&nbsp;</span>Friends</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(9)"><span class="SelectionMark">&nbsp;</span>Defines</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<hr size="1"/><address style="text-align: right;"><small>Generated on 16 Mar 2010 for ICU 4.4 by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.1 </small></address>
</body>
</html>