Sophie

Sophie

distrib > Mandriva > 2008.1 > x86_64 > media > main-testing > by-pkgid > 2c50825dd66d0497b96a67f7fab2ee84 > files > 3967

openoffice.org64-devel-doc-2.4.1.10-1mdv2008.1.x86_64.rpm

<html>
<head>
<title>Interface XTextInputStream</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link rel="stylesheet" type="text/css" href="../../../../idl.css">
</head>
<body>
<div id="adc-idlref">

<a name="_top_"> </a><table class="navimain" border="0" cellpadding="3">
<tr>
<td class="navimain"><a href="../module-ix.html" class="navimain">Overview</a></td>
<td class="navimain"><a href="module-ix.html" class="navimain">Module</a></td>
<td class="navimain"><a href="XTextInputStream-xref.html" class="navimain">Use</a></td>
<td class="navimainnone">Devguide</td>
<td class="navimain"><a href="../../../../index-files/index-1.html" class="navimain">Index</a></td>
</tr>
</table>
<table class="navisub" border="0" cellpadding="0">
<tr>
<td class="navisub"><a href="#MethodsSummary" class="navisub">Methods' Summary</a></td>
<td class="navisub"><a href="#MethodsDetails" class="navisub">Methods' Details</a></td>
<td class="navisub">Attributes' Summary</td>
<td class="navisub">Attributes' Details</td>
</tr>
</table>
<hr>
<table border="0" width="100%" cellpadding="5" cellspacing="3" class="title-table" style="margin-bottom:6pt;">
<tr>
<td><p class="namechain"><a href="../../../../module-ix.html" class="namechain">::</a> <a href="../../../module-ix.html" class="namechain">com</a> :: <a href="../../module-ix.html" class="namechain">sun</a> :: <a href="../module-ix.html" class="namechain">star</a> :: <a href="module-ix.html" class="namechain">io</a> :: </p>
</td>
</tr>
<tr>
<td class="title">interface XTextInputStream</td>
</tr>
<tr>
<td><dl>
<dt><b>Base Interfaces</b></dt>
<dd><pre style="font-family:monospace;"><strong>XTextInputStream</strong>
&#x2517 <a href="XInputStream.html">XInputStream</a>

</pre></dd>
<dd><a name/><table border="1" width="100%" cellpadding="5" cellspacing="0" class="crosstitle">
<tr>
<td class="imsum_left"><a href="XInputStream.html">XInputStream</a></td>
<td class="imsum_right"><dl>
<dt>(referenced interface's summary:)</dt>
<dd>This is the basic interface to read data from a stream.
 </dd>
</dl>
</td>
</tr>
</table>
</dd>
</dl>
</td>
</tr>
<tr>
<td><dl>
<dt><b>Description</b></dt>
<dd>Interface to read strings from a stream.

 </dd>
<dd><p>This interfaces allows to read strings seperated by 
 delimiters and to read lines. The character encoding
 to be used can be set by <a href="XTextInputStream.html#setEncoding()">setEncoding()</a>.
 Default encoding is "utf8".</p>
 </dd>
</dl>
</td>
</tr>
</table>
<hr>
<a name="MethodsSummary"/><table border="1" width="100%" cellpadding="5" cellspacing="0" class="subtitle">
<tr>
<td class="subtitle" colspan="2">Methods' Summary</td>
</tr>
<tr>
<td class="imsum_left"><a href="#readLine">readLine</a></td>
<td class="imsum_right">reads text until a line break (CR, LF, or CR/LF) or 
 EOF is found and returns it as string (without CR, LF). 

 &nbsp;</td>
</tr>
<tr>
<td class="imsum_left"><a href="#readString">readString</a></td>
<td class="imsum_right">reads text until one of the given delimiter characters 
 or EOF is found and returns it as string (without delimiter).

 &nbsp;</td>
</tr>
<tr>
<td class="imsum_left"><a href="#isEOF">isEOF</a></td>
<td class="imsum_right">Returns the EOF status.

 &nbsp;</td>
</tr>
<tr>
<td class="imsum_left"><a href="#setEncoding">setEncoding</a></td>
<td class="imsum_right">sets character encoding.

 &nbsp;</td>
</tr>
</table>
<a name="MethodsDetails"/><table border="1" width="100%" cellpadding="5" cellspacing="0" class="subtitle">
<tr>
<td class="subtitle">Methods' Details</td>
</tr>
<tr>
<td class="imdetail"><a name="readLine" class="membertitle">readLine</a><table border="0" width="96%" cellpadding="5" cellspacing="0" class="table-in-method" bgcolor="#ffffff" align="center">
<tr>
<td><table class="table-in-method" border="0">
<tr>
<td valign="top" colspan="3">string</td>
</tr>
<tr>
<td valign="top"><b>readLine</b>()</td>
</tr>
<tr>
<td valign="top" align="right">raises( </td>
<td valign="top" colspan="2"><a href="IOException.html">IOException</a> );</td>
</tr>
</table>
<hr>
<dl>
<dt><b>Description</b></dt>
<dd>reads text until a line break (CR, LF, or CR/LF) or 
 EOF is found and returns it as string (without CR, LF). 

 </dd>
<dd><p>The read characters are converted according to the 
 encoding defined by <a href="#setEncoding">setEncoding</a>. If
 EOF is already reached before calling this method
 an empty string is returned.<p>

 </dd>
<dt><b>See also</b></dt>
<dd><a href="#setEncoding">setEncoding</a>, <a href="#isEOF">isEOF</a></dd>
</dl>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td class="imdetail"><a name="readString" class="membertitle">readString</a><table border="0" width="96%" cellpadding="5" cellspacing="0" class="table-in-method" bgcolor="#ffffff" align="center">
<tr>
<td><table class="table-in-method" border="0">
<tr>
<td valign="top" colspan="3">string</td>
</tr>
<tr>
<td valign="top"><b>readString</b>(</td>
<td valign="top">[in] sequence&lt; char &gt;</td>
<td valign="bottom">&nbsp;Delimiters,</td>
</tr>
<tr>
<td/><td valign="top">[in] boolean</td>
<td valign="bottom">&nbsp;bRemoveDelimiter )</td>
</tr>
<tr>
<td valign="top" align="right">raises( </td>
<td valign="top" colspan="2"><a href="IOException.html">IOException</a> );</td>
</tr>
</table>
<hr>
<dl>
<dt><b>Description</b></dt>
<dd>reads text until one of the given delimiter characters 
 or EOF is found and returns it as string (without delimiter).

 </dd>
<dd><p><strong>Important:</strong> CR/LF is not used as default 
 delimiter! So if no delimiter is defined or none of the 
 delimiters is found, the stream will be read to EOF. The 
 read characters are converted according to the encoding
 defined by <a href="#setEncoding">setEncoding</a>. If EOF is already 
 reached before calling this method an empty string is returned.</p>

 </dd>
<dt><b>See also</b></dt>
<dd><a href="#setEncoding">setEncoding</a>, <a href="#isEOF">isEOF</a></dd>
</dl>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td class="imdetail"><a name="isEOF" class="membertitle">isEOF</a><table border="0" width="96%" cellpadding="5" cellspacing="0" class="table-in-method" bgcolor="#ffffff" align="center">
<tr>
<td><table class="table-in-method" border="0">
<tr>
<td valign="top" colspan="3">boolean</td>
</tr>
<tr>
<td valign="top"><b>isEOF</b>()</td>
</tr>
<tr>
<td valign="top" align="right">raises( </td>
<td valign="top" colspan="2"><a href="IOException.html">IOException</a> );</td>
</tr>
</table>
<hr>
<dl>
<dt><b>Description</b></dt>
<dd>Returns the EOF status.

 </dd>
<dd><p>This method has to be used to detect if the end
 of the stream is reached.</p> 
 <p><strong>Important:</strong>
 This cannot be detected by asking for an empty string
 because that can be a valid return value of 
 <a href="#readLine()">readLine()</a> (if the line is empty) and
 readString() (if a delimiter is directly followed
 by the next one).</p>
 
 </dd>
<dt><b>Returns</b></dt>
<dd><b>true</b>, if the end of file is reached, so that 
 no next string can be read. <b>false</b> otherwise
 </dd>
</dl>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td class="imdetail"><a name="setEncoding" class="membertitle">setEncoding</a><table border="0" width="96%" cellpadding="5" cellspacing="0" class="table-in-method" bgcolor="#ffffff" align="center">
<tr>
<td><table class="table-in-method" border="0">
<tr>
<td valign="top" colspan="3">void</td>
</tr>
<tr>
<td valign="top"><b>setEncoding</b>(</td>
<td valign="top">[in] string</td>
<td valign="bottom">&nbsp;Encoding );</td>
</tr>
</table>
<hr>
<dl>
<dt><b>Description</b></dt>
<dd>sets character encoding.

 </dd>
<dt><b>Parameter Encoding</b></dt>
<dd>sets the character encoding that should be used.
 The character encoding names refer to the document
 http://www.iana.org/assignments/character-sets.
 Which character sets are supported depends on
 the implementation.
 </dd>
</dl>
</td>
</tr>
</table>
</td>
</tr>
</table>
<a href="#_top_">Top of Page</a><hr size="3"><p class="copyright" align="center">Copyright &copy; 2008 Sun Microsystems, Inc.</p>

</div> <!-- id="adc-idlref" -->
</body>

</html>