653 lines
32 KiB
HTML
653 lines
32 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
|
<!-- NewPage -->
|
|
<html lang="nl">
|
|
<head>
|
|
<!-- Generated by javadoc (version 1.7.0_40) on Tue Oct 15 12:25:31 CEST 2013 -->
|
|
<title>FileStream</title>
|
|
<meta name="date" content="2013-10-15">
|
|
<link rel="stylesheet" type="text/css" href="../../stylesheet.css" title="Style">
|
|
</head>
|
|
<body>
|
|
<script type="text/javascript"><!--
|
|
if (location.href.indexOf('is-external=true') == -1) {
|
|
parent.document.title="FileStream";
|
|
}
|
|
//-->
|
|
</script>
|
|
<noscript>
|
|
<div>JavaScript is disabled on your browser.</div>
|
|
</noscript>
|
|
<!-- ========= START OF TOP NAVBAR ======= -->
|
|
<div class="topNav"><a name="navbar_top">
|
|
<!-- -->
|
|
</a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="navList" title="Navigation">
|
|
<li><a href="../../overview-summary.html">Overview</a></li>
|
|
<li><a href="package-summary.html">Package</a></li>
|
|
<li class="navBarCell1Rev">Class</li>
|
|
<li><a href="class-use/FileStream.html">Use</a></li>
|
|
<li><a href="package-tree.html">Tree</a></li>
|
|
<li><a href="../../deprecated-list.html">Deprecated</a></li>
|
|
<li><a href="../../index-files/index-1.html">Index</a></li>
|
|
<li><a href="../../help-doc.html">Help</a></li>
|
|
</ul>
|
|
</div>
|
|
<div class="subNav">
|
|
<ul class="navList">
|
|
<li><a href="../../System/IO/FileShare.html" title="enum in System.IO"><span class="strong">Prev Class</span></a></li>
|
|
<li><a href="../../System/IO/IOException.html" title="class in System.IO"><span class="strong">Next Class</span></a></li>
|
|
</ul>
|
|
<ul class="navList">
|
|
<li><a href="../../index.html?System/IO/FileStream.html" target="_top">Frames</a></li>
|
|
<li><a href="FileStream.html" target="_top">No Frames</a></li>
|
|
</ul>
|
|
<ul class="navList" id="allclasses_navbar_top">
|
|
<li><a href="../../allclasses-noframe.html">All Classes</a></li>
|
|
</ul>
|
|
<div>
|
|
<script type="text/javascript"><!--
|
|
allClassesLink = document.getElementById("allclasses_navbar_top");
|
|
if(window==top) {
|
|
allClassesLink.style.display = "block";
|
|
}
|
|
else {
|
|
allClassesLink.style.display = "none";
|
|
}
|
|
//-->
|
|
</script>
|
|
</div>
|
|
<div>
|
|
<ul class="subNavList">
|
|
<li>Summary: </li>
|
|
<li>Nested | </li>
|
|
<li><a href="#fields_inherited_from_class_System.IO.Stream">Field</a> | </li>
|
|
<li><a href="#constructor_summary">Constr</a> | </li>
|
|
<li><a href="#method_summary">Method</a></li>
|
|
</ul>
|
|
<ul class="subNavList">
|
|
<li>Detail: </li>
|
|
<li>Field | </li>
|
|
<li><a href="#constructor_detail">Constr</a> | </li>
|
|
<li><a href="#method_detail">Method</a></li>
|
|
</ul>
|
|
</div>
|
|
<a name="skip-navbar_top">
|
|
<!-- -->
|
|
</a></div>
|
|
<!-- ========= END OF TOP NAVBAR ========= -->
|
|
<!-- ======== START OF CLASS DATA ======== -->
|
|
<div class="header">
|
|
<div class="subTitle">System.IO</div>
|
|
<h2 title="Class FileStream" class="title">Class FileStream</h2>
|
|
</div>
|
|
<div class="contentContainer">
|
|
<ul class="inheritance">
|
|
<li>java.lang.Object</li>
|
|
<li>
|
|
<ul class="inheritance">
|
|
<li><a href="../../System/IO/Stream.html" title="class in System.IO">System.IO.Stream</a></li>
|
|
<li>
|
|
<ul class="inheritance">
|
|
<li>System.IO.FileStream</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
<div class="description">
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<dl>
|
|
<dt>All Implemented Interfaces:</dt>
|
|
<dd><a href="../../System/IDisposable.html" title="interface in System">IDisposable</a></dd>
|
|
</dl>
|
|
<dl>
|
|
<dt>Direct Known Subclasses:</dt>
|
|
<dd><a href="../../System/IO/IsolatedStorage/IsolatedStorageFileStream.html" title="class in System.IO.IsolatedStorage">IsolatedStorageFileStream</a></dd>
|
|
</dl>
|
|
<hr>
|
|
<br>
|
|
<pre>public class <span class="strong">FileStream</span>
|
|
extends <a href="../../System/IO/Stream.html" title="class in System.IO">Stream</a></pre>
|
|
<div class="block">When it is called by an elevated-trust application, exposes a System.IO.Stream around a file, supporting both synchronous and asynchronous read and write operations.</div>
|
|
<dl><dt><span class="strong">Author:</span></dt>
|
|
<dd>Halofreak1990</dd></dl>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
<div class="summary">
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<!-- =========== FIELD SUMMARY =========== -->
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="field_summary">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Field Summary</h3>
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="fields_inherited_from_class_System.IO.Stream">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Fields inherited from class System.IO.<a href="../../System/IO/Stream.html" title="class in System.IO">Stream</a></h3>
|
|
<code><a href="../../System/IO/Stream.html#Null">Null</a></code></li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="constructor_summary">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Constructor Summary</h3>
|
|
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
|
|
<caption><span>Constructors</span><span class="tabEnd"> </span></caption>
|
|
<tr>
|
|
<th class="colFirst" scope="col">Modifier</th>
|
|
<th class="colLast" scope="col">Constructor and Description</th>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>protected </code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#FileStream()">FileStream</a></strong>()</code> </td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code> </code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#FileStream(java.lang.String, System.IO.FileMode)">FileStream</a></strong>(java.lang.String path,
|
|
<a href="../../System/IO/FileMode.html" title="enum in System.IO">FileMode</a> mode)</code>
|
|
<div class="block">When it is called by trusted applications, initializes a new instance of the System.IO.FileStream class with the specified path and creation mode.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code> </code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#FileStream(java.lang.String, System.IO.FileMode, java.util.EnumSet)">FileStream</a></strong>(java.lang.String path,
|
|
<a href="../../System/IO/FileMode.html" title="enum in System.IO">FileMode</a> mode,
|
|
java.util.EnumSet<<a href="../../System/IO/FileAccess.html" title="enum in System.IO">FileAccess</a>> access)</code>
|
|
<div class="block">When it is called by trusted applications, initializes a new instance of the System.IO.FileStream class with the specified path, creation mode, and read/write permission.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code> </code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#FileStream(java.lang.String, System.IO.FileMode, java.util.EnumSet, java.util.EnumSet)">FileStream</a></strong>(java.lang.String path,
|
|
<a href="../../System/IO/FileMode.html" title="enum in System.IO">FileMode</a> mode,
|
|
java.util.EnumSet<<a href="../../System/IO/FileAccess.html" title="enum in System.IO">FileAccess</a>> access,
|
|
java.util.EnumSet<<a href="../../System/IO/FileShare.html" title="enum in System.IO">FileShare</a>> share)</code> </td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code> </code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#FileStream(java.lang.String, System.IO.FileMode, java.util.EnumSet, java.util.EnumSet, int)">FileStream</a></strong>(java.lang.String path,
|
|
<a href="../../System/IO/FileMode.html" title="enum in System.IO">FileMode</a> mode,
|
|
java.util.EnumSet<<a href="../../System/IO/FileAccess.html" title="enum in System.IO">FileAccess</a>> access,
|
|
java.util.EnumSet<<a href="../../System/IO/FileShare.html" title="enum in System.IO">FileShare</a>> share,
|
|
int bufferSize)</code> </td>
|
|
</tr>
|
|
</table>
|
|
</li>
|
|
</ul>
|
|
<!-- ========== METHOD SUMMARY =========== -->
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="method_summary">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Method Summary</h3>
|
|
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
|
|
<caption><span>Methods</span><span class="tabEnd"> </span></caption>
|
|
<tr>
|
|
<th class="colFirst" scope="col">Modifier and Type</th>
|
|
<th class="colLast" scope="col">Method and Description</th>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>boolean</code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#CanRead()">CanRead</a></strong>()</code>
|
|
<div class="block">When overridden in a derived class, gets a value indicating whether the current stream supports reading.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>boolean</code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#CanSeek()">CanSeek</a></strong>()</code>
|
|
<div class="block">When overridden in a derived class, gets a value indicating whether the current stream supports seeking.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>boolean</code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#CanWrite()">CanWrite</a></strong>()</code>
|
|
<div class="block">When overridden in a derived class, gets a value indicating whether the current stream supports writing.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>protected void</code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#finalize()">finalize</a></strong>()</code>
|
|
<div class="block">Ensures that resources are freed and other cleanup operations are performed when the garbage collector reclaims the FileStream.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>void</code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#Flush()">Flush</a></strong>()</code>
|
|
<div class="block">When overridden in a derived class, clears all buffers for this stream and causes any buffered data to be written to the underlying device.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>java.lang.String</code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#getName()">getName</a></strong>()</code> </td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>long</code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#getPosition()">getPosition</a></strong>()</code>
|
|
<div class="block">When overridden in a derived class, gets the position within the current stream.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>long</code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#Length()">Length</a></strong>()</code>
|
|
<div class="block">When overridden in a derived class, gets the length in bytes of the stream.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>int</code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#Read(byte[], int, int)">Read</a></strong>(byte[] buffer,
|
|
int offset,
|
|
int count)</code>
|
|
<div class="block">When overridden in a derived class, reads a sequence of bytes from the current stream and advances the position within the stream by the number of bytes read.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>long</code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#Seek(long, System.IO.SeekOrigin)">Seek</a></strong>(long offset,
|
|
<a href="../../System/IO/SeekOrigin.html" title="enum in System.IO">SeekOrigin</a> origin)</code>
|
|
<div class="block">When overridden in a derived class, sets the position within the current stream.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>void</code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#SetLength(long)">SetLength</a></strong>(long value)</code>
|
|
<div class="block">When overridden in a derived class, sets the length of the current stream.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>void</code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#setPosition(long)">setPosition</a></strong>(long value)</code>
|
|
<div class="block">When overridden in a derived class, sets the position within the current stream.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>void</code></td>
|
|
<td class="colLast"><code><strong><a href="../../System/IO/FileStream.html#Write(byte[], int, int)">Write</a></strong>(byte[] buffer,
|
|
int offset,
|
|
int count)</code>
|
|
<div class="block">When overridden in a derived class, writes a sequence of bytes to the current stream and advances the current position within this stream by the number of bytes written.</div>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="methods_inherited_from_class_System.IO.Stream">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Methods inherited from class System.IO.<a href="../../System/IO/Stream.html" title="class in System.IO">Stream</a></h3>
|
|
<code><a href="../../System/IO/Stream.html#BeginRead(byte[], int, int, System.AsyncCallback, java.lang.Object)">BeginRead</a>, <a href="../../System/IO/Stream.html#BeginWrite(byte[], int, int, System.AsyncCallback, java.lang.Object)">BeginWrite</a>, <a href="../../System/IO/Stream.html#CanTimeout()">CanTimeout</a>, <a href="../../System/IO/Stream.html#Close()">Close</a>, <a href="../../System/IO/Stream.html#Dispose()">Dispose</a>, <a href="../../System/IO/Stream.html#Dispose(boolean)">Dispose</a>, <a href="../../System/IO/Stream.html#EndRead(System.IAsyncResult)">EndRead</a>, <a href="../../System/IO/Stream.html#EndWrite(System.IAsyncResult)">EndWrite</a>, <a href="../../System/IO/Stream.html#ReadByte()">ReadByte</a>, <a href="../../System/IO/Stream.html#WriteByte(byte)">WriteByte</a></code></li>
|
|
</ul>
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="methods_inherited_from_class_java.lang.Object">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Methods inherited from class java.lang.Object</h3>
|
|
<code>clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</code></li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
<div class="details">
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<!-- ========= CONSTRUCTOR DETAIL ======== -->
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="constructor_detail">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Constructor Detail</h3>
|
|
<a name="FileStream()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>FileStream</h4>
|
|
<pre>protected FileStream()</pre>
|
|
</li>
|
|
</ul>
|
|
<a name="FileStream(java.lang.String, System.IO.FileMode)">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>FileStream</h4>
|
|
<pre>public FileStream(java.lang.String path,
|
|
<a href="../../System/IO/FileMode.html" title="enum in System.IO">FileMode</a> mode)</pre>
|
|
<div class="block">When it is called by trusted applications, initializes a new instance of the System.IO.FileStream class with the specified path and creation mode.</div>
|
|
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>path</code> - A relative or absolute path for the file that the current FileStream object will encapsulate.</dd><dd><code>mode</code> - A System.IO.FileMode constant that determines how to open or create the file.</dd>
|
|
<dt><span class="strong">Throws:</span></dt>
|
|
<dd><code><a href="../../System/ArgumentException.html" title="class in System">ArgumentException</a></code> - path is an empty string (""), contains only white space, or contains one or more invalid characters. -or-path refers to a non-file device, such as "con:", "com1:", "lpt1:", etc. in an NTFS environment.</dd>
|
|
<dd><code><a href="../../System/NotSupportedException.html" title="class in System">NotSupportedException</a></code> - path refers to a non-file device, such as "con:", "com1:", "lpt1:", etc. in a non-NTFS environment.</dd>
|
|
<dd><code><a href="../../System/ArgumentNullException.html" title="class in System">ArgumentNullException</a></code> - path is null.</dd>
|
|
<dd><code>System.Security.SecurityException</code> - The caller does not have the required permission.</dd>
|
|
<dd><code><a href="../../System/IO/FileNotFoundException.html" title="class in System.IO">FileNotFoundException</a></code> - The file cannot be found, such as when mode is FileMode.Truncate or FileMode.Open, and the file specified by path does not exist. The file must already exist in these modes.</dd>
|
|
<dd><code><a href="../../System/IO/IOException.html" title="class in System.IO">IOException</a></code> - An I/O error occurs, such as specifying FileMode.CreateNew and the file specified by path already exists.-or-The stream has been closed.</dd>
|
|
<dd><code><a href="../../System/IO/PathTooLongException.html" title="class in System.IO">PathTooLongException</a></code> - The specified path, file name, or both exceed the system-defined maximum length. For example, on Windows-based platforms, paths must be less than 248 characters, and file names must be less than 260 characters.</dd></dl>
|
|
</li>
|
|
</ul>
|
|
<a name="FileStream(java.lang.String, System.IO.FileMode, java.util.EnumSet)">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>FileStream</h4>
|
|
<pre>public FileStream(java.lang.String path,
|
|
<a href="../../System/IO/FileMode.html" title="enum in System.IO">FileMode</a> mode,
|
|
java.util.EnumSet<<a href="../../System/IO/FileAccess.html" title="enum in System.IO">FileAccess</a>> access)</pre>
|
|
<div class="block">When it is called by trusted applications, initializes a new instance of the System.IO.FileStream class with the specified path, creation mode, and read/write permission.</div>
|
|
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>path</code> - </dd><dd><code>mode</code> - </dd><dd><code>access</code> - </dd></dl>
|
|
</li>
|
|
</ul>
|
|
<a name="FileStream(java.lang.String, System.IO.FileMode, java.util.EnumSet, java.util.EnumSet)">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>FileStream</h4>
|
|
<pre>public FileStream(java.lang.String path,
|
|
<a href="../../System/IO/FileMode.html" title="enum in System.IO">FileMode</a> mode,
|
|
java.util.EnumSet<<a href="../../System/IO/FileAccess.html" title="enum in System.IO">FileAccess</a>> access,
|
|
java.util.EnumSet<<a href="../../System/IO/FileShare.html" title="enum in System.IO">FileShare</a>> share)</pre>
|
|
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>path</code> - </dd><dd><code>mode</code> - </dd><dd><code>access</code> - </dd><dd><code>share</code> - </dd></dl>
|
|
</li>
|
|
</ul>
|
|
<a name="FileStream(java.lang.String, System.IO.FileMode, java.util.EnumSet, java.util.EnumSet, int)">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>FileStream</h4>
|
|
<pre>public FileStream(java.lang.String path,
|
|
<a href="../../System/IO/FileMode.html" title="enum in System.IO">FileMode</a> mode,
|
|
java.util.EnumSet<<a href="../../System/IO/FileAccess.html" title="enum in System.IO">FileAccess</a>> access,
|
|
java.util.EnumSet<<a href="../../System/IO/FileShare.html" title="enum in System.IO">FileShare</a>> share,
|
|
int bufferSize)</pre>
|
|
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>path</code> - </dd><dd><code>mode</code> - </dd><dd><code>access</code> - </dd><dd><code>share</code> - </dd><dd><code>bufferSize</code> - </dd></dl>
|
|
</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
<!-- ============ METHOD DETAIL ========== -->
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="method_detail">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Method Detail</h3>
|
|
<a name="CanRead()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>CanRead</h4>
|
|
<pre>public boolean CanRead()</pre>
|
|
<div class="block"><strong>Description copied from class: <code><a href="../../System/IO/Stream.html#CanRead()">Stream</a></code></strong></div>
|
|
<div class="block">When overridden in a derived class, gets a value indicating whether the current stream supports reading.</div>
|
|
<dl>
|
|
<dt><strong>Specified by:</strong></dt>
|
|
<dd><code><a href="../../System/IO/Stream.html#CanRead()">CanRead</a></code> in class <code><a href="../../System/IO/Stream.html" title="class in System.IO">Stream</a></code></dd>
|
|
<dt><span class="strong">Returns:</span></dt><dd>true if the stream supports reading; otherwise, false.</dd></dl>
|
|
</li>
|
|
</ul>
|
|
<a name="CanSeek()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>CanSeek</h4>
|
|
<pre>public boolean CanSeek()</pre>
|
|
<div class="block"><strong>Description copied from class: <code><a href="../../System/IO/Stream.html#CanSeek()">Stream</a></code></strong></div>
|
|
<div class="block">When overridden in a derived class, gets a value indicating whether the current stream supports seeking.</div>
|
|
<dl>
|
|
<dt><strong>Specified by:</strong></dt>
|
|
<dd><code><a href="../../System/IO/Stream.html#CanSeek()">CanSeek</a></code> in class <code><a href="../../System/IO/Stream.html" title="class in System.IO">Stream</a></code></dd>
|
|
<dt><span class="strong">Returns:</span></dt><dd>true if the stream supports seeking; otherwise, false.</dd></dl>
|
|
</li>
|
|
</ul>
|
|
<a name="CanWrite()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>CanWrite</h4>
|
|
<pre>public boolean CanWrite()</pre>
|
|
<div class="block"><strong>Description copied from class: <code><a href="../../System/IO/Stream.html#CanWrite()">Stream</a></code></strong></div>
|
|
<div class="block">When overridden in a derived class, gets a value indicating whether the current stream supports writing.</div>
|
|
<dl>
|
|
<dt><strong>Specified by:</strong></dt>
|
|
<dd><code><a href="../../System/IO/Stream.html#CanWrite()">CanWrite</a></code> in class <code><a href="../../System/IO/Stream.html" title="class in System.IO">Stream</a></code></dd>
|
|
<dt><span class="strong">Returns:</span></dt><dd>true if the stream supports writing; otherwise, false.</dd></dl>
|
|
</li>
|
|
</ul>
|
|
<a name="Length()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>Length</h4>
|
|
<pre>public long Length()</pre>
|
|
<div class="block"><strong>Description copied from class: <code><a href="../../System/IO/Stream.html#Length()">Stream</a></code></strong></div>
|
|
<div class="block">When overridden in a derived class, gets the length in bytes of the stream.</div>
|
|
<dl>
|
|
<dt><strong>Specified by:</strong></dt>
|
|
<dd><code><a href="../../System/IO/Stream.html#Length()">Length</a></code> in class <code><a href="../../System/IO/Stream.html" title="class in System.IO">Stream</a></code></dd>
|
|
<dt><span class="strong">Returns:</span></dt><dd>A long value representing the length of the stream in bytes.</dd></dl>
|
|
</li>
|
|
</ul>
|
|
<a name="getName()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>getName</h4>
|
|
<pre>public java.lang.String getName()</pre>
|
|
</li>
|
|
</ul>
|
|
<a name="getPosition()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>getPosition</h4>
|
|
<pre>public long getPosition()</pre>
|
|
<div class="block"><strong>Description copied from class: <code><a href="../../System/IO/Stream.html#getPosition()">Stream</a></code></strong></div>
|
|
<div class="block">When overridden in a derived class, gets the position within the current stream.</div>
|
|
<dl>
|
|
<dt><strong>Specified by:</strong></dt>
|
|
<dd><code><a href="../../System/IO/Stream.html#getPosition()">getPosition</a></code> in class <code><a href="../../System/IO/Stream.html" title="class in System.IO">Stream</a></code></dd>
|
|
<dt><span class="strong">Returns:</span></dt><dd>The current position within the stream.</dd></dl>
|
|
</li>
|
|
</ul>
|
|
<a name="setPosition(long)">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>setPosition</h4>
|
|
<pre>public void setPosition(long value)</pre>
|
|
<div class="block"><strong>Description copied from class: <code><a href="../../System/IO/Stream.html#setPosition(long)">Stream</a></code></strong></div>
|
|
<div class="block">When overridden in a derived class, sets the position within the current stream.</div>
|
|
<dl>
|
|
<dt><strong>Specified by:</strong></dt>
|
|
<dd><code><a href="../../System/IO/Stream.html#setPosition(long)">setPosition</a></code> in class <code><a href="../../System/IO/Stream.html" title="class in System.IO">Stream</a></code></dd>
|
|
<dt><span class="strong">Parameters:</span></dt><dd><code>value</code> - The new position within the stream.</dd></dl>
|
|
</li>
|
|
</ul>
|
|
<a name="finalize()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>finalize</h4>
|
|
<pre>protected void finalize()</pre>
|
|
<div class="block">Ensures that resources are freed and other cleanup operations are performed when the garbage collector reclaims the FileStream.</div>
|
|
<dl>
|
|
<dt><strong>Overrides:</strong></dt>
|
|
<dd><code>finalize</code> in class <code>java.lang.Object</code></dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a name="Flush()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>Flush</h4>
|
|
<pre>public void Flush()</pre>
|
|
<div class="block"><strong>Description copied from class: <code><a href="../../System/IO/Stream.html#Flush()">Stream</a></code></strong></div>
|
|
<div class="block">When overridden in a derived class, clears all buffers for this stream and causes any buffered data to be written to the underlying device.</div>
|
|
<dl>
|
|
<dt><strong>Specified by:</strong></dt>
|
|
<dd><code><a href="../../System/IO/Stream.html#Flush()">Flush</a></code> in class <code><a href="../../System/IO/Stream.html" title="class in System.IO">Stream</a></code></dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a name="Read(byte[], int, int)">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>Read</h4>
|
|
<pre>public int Read(byte[] buffer,
|
|
int offset,
|
|
int count)</pre>
|
|
<div class="block"><strong>Description copied from class: <code><a href="../../System/IO/Stream.html#Read(byte[], int, int)">Stream</a></code></strong></div>
|
|
<div class="block">When overridden in a derived class, reads a sequence of bytes from the current stream and advances the position within the stream by the number of bytes read.</div>
|
|
<dl>
|
|
<dt><strong>Specified by:</strong></dt>
|
|
<dd><code><a href="../../System/IO/Stream.html#Read(byte[], int, int)">Read</a></code> in class <code><a href="../../System/IO/Stream.html" title="class in System.IO">Stream</a></code></dd>
|
|
<dt><span class="strong">Parameters:</span></dt><dd><code>buffer</code> - An array of bytes. When this method returns, the buffer contains the specified byte array with the values between offset and (offset + count - 1) replaced by the bytes read from the current source.</dd><dd><code>offset</code> - The zero-based byte offset in buffer at which to begin storing the data read from the current stream.</dd><dd><code>count</code> - The maximum number of bytes to be read from the current stream.</dd>
|
|
<dt><span class="strong">Returns:</span></dt><dd>The total number of bytes read into the buffer. This can be less than the number of bytes requested if that many bytes are not currently available, or zero (0) if the end of the stream has been reached.</dd></dl>
|
|
</li>
|
|
</ul>
|
|
<a name="Seek(long, System.IO.SeekOrigin)">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>Seek</h4>
|
|
<pre>public long Seek(long offset,
|
|
<a href="../../System/IO/SeekOrigin.html" title="enum in System.IO">SeekOrigin</a> origin)</pre>
|
|
<div class="block"><strong>Description copied from class: <code><a href="../../System/IO/Stream.html#Seek(long, System.IO.SeekOrigin)">Stream</a></code></strong></div>
|
|
<div class="block">When overridden in a derived class, sets the position within the current stream.</div>
|
|
<dl>
|
|
<dt><strong>Specified by:</strong></dt>
|
|
<dd><code><a href="../../System/IO/Stream.html#Seek(long, System.IO.SeekOrigin)">Seek</a></code> in class <code><a href="../../System/IO/Stream.html" title="class in System.IO">Stream</a></code></dd>
|
|
<dt><span class="strong">Parameters:</span></dt><dd><code>offset</code> - A byte offset relative to the origin parameter.</dd><dd><code>origin</code> - A value of type System.IO.SeekOrigin indicating the reference point used to obtain the new position.</dd>
|
|
<dt><span class="strong">Returns:</span></dt><dd>The new position within the current stream.</dd></dl>
|
|
</li>
|
|
</ul>
|
|
<a name="SetLength(long)">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>SetLength</h4>
|
|
<pre>public void SetLength(long value)</pre>
|
|
<div class="block"><strong>Description copied from class: <code><a href="../../System/IO/Stream.html#SetLength(long)">Stream</a></code></strong></div>
|
|
<div class="block">When overridden in a derived class, sets the length of the current stream.</div>
|
|
<dl>
|
|
<dt><strong>Specified by:</strong></dt>
|
|
<dd><code><a href="../../System/IO/Stream.html#SetLength(long)">SetLength</a></code> in class <code><a href="../../System/IO/Stream.html" title="class in System.IO">Stream</a></code></dd>
|
|
<dt><span class="strong">Parameters:</span></dt><dd><code>value</code> - The desired length of the current stream in bytes.</dd></dl>
|
|
</li>
|
|
</ul>
|
|
<a name="Write(byte[], int, int)">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>Write</h4>
|
|
<pre>public void Write(byte[] buffer,
|
|
int offset,
|
|
int count)</pre>
|
|
<div class="block"><strong>Description copied from class: <code><a href="../../System/IO/Stream.html#Write(byte[], int, int)">Stream</a></code></strong></div>
|
|
<div class="block">When overridden in a derived class, writes a sequence of bytes to the current stream and advances the current position within this stream by the number of bytes written.</div>
|
|
<dl>
|
|
<dt><strong>Specified by:</strong></dt>
|
|
<dd><code><a href="../../System/IO/Stream.html#Write(byte[], int, int)">Write</a></code> in class <code><a href="../../System/IO/Stream.html" title="class in System.IO">Stream</a></code></dd>
|
|
<dt><span class="strong">Parameters:</span></dt><dd><code>buffer</code> - </dd><dd><code>offset</code> - </dd><dd><code>count</code> - </dd>
|
|
<dt><span class="strong">Throws:</span></dt>
|
|
<dd><code><a href="../../System/ArgumentNullException.html" title="class in System">ArgumentNullException</a></code> - buffer is null.</dd>
|
|
<dd><code><a href="../../System/ArgumentOutOfRangeException.html" title="class in System">ArgumentOutOfRangeException</a></code></dd></dl>
|
|
</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<!-- ========= END OF CLASS DATA ========= -->
|
|
<!-- ======= START OF BOTTOM NAVBAR ====== -->
|
|
<div class="bottomNav"><a name="navbar_bottom">
|
|
<!-- -->
|
|
</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="navList" title="Navigation">
|
|
<li><a href="../../overview-summary.html">Overview</a></li>
|
|
<li><a href="package-summary.html">Package</a></li>
|
|
<li class="navBarCell1Rev">Class</li>
|
|
<li><a href="class-use/FileStream.html">Use</a></li>
|
|
<li><a href="package-tree.html">Tree</a></li>
|
|
<li><a href="../../deprecated-list.html">Deprecated</a></li>
|
|
<li><a href="../../index-files/index-1.html">Index</a></li>
|
|
<li><a href="../../help-doc.html">Help</a></li>
|
|
</ul>
|
|
</div>
|
|
<div class="subNav">
|
|
<ul class="navList">
|
|
<li><a href="../../System/IO/FileShare.html" title="enum in System.IO"><span class="strong">Prev Class</span></a></li>
|
|
<li><a href="../../System/IO/IOException.html" title="class in System.IO"><span class="strong">Next Class</span></a></li>
|
|
</ul>
|
|
<ul class="navList">
|
|
<li><a href="../../index.html?System/IO/FileStream.html" target="_top">Frames</a></li>
|
|
<li><a href="FileStream.html" target="_top">No Frames</a></li>
|
|
</ul>
|
|
<ul class="navList" id="allclasses_navbar_bottom">
|
|
<li><a href="../../allclasses-noframe.html">All Classes</a></li>
|
|
</ul>
|
|
<div>
|
|
<script type="text/javascript"><!--
|
|
allClassesLink = document.getElementById("allclasses_navbar_bottom");
|
|
if(window==top) {
|
|
allClassesLink.style.display = "block";
|
|
}
|
|
else {
|
|
allClassesLink.style.display = "none";
|
|
}
|
|
//-->
|
|
</script>
|
|
</div>
|
|
<div>
|
|
<ul class="subNavList">
|
|
<li>Summary: </li>
|
|
<li>Nested | </li>
|
|
<li><a href="#fields_inherited_from_class_System.IO.Stream">Field</a> | </li>
|
|
<li><a href="#constructor_summary">Constr</a> | </li>
|
|
<li><a href="#method_summary">Method</a></li>
|
|
</ul>
|
|
<ul class="subNavList">
|
|
<li>Detail: </li>
|
|
<li>Field | </li>
|
|
<li><a href="#constructor_detail">Constr</a> | </li>
|
|
<li><a href="#method_detail">Method</a></li>
|
|
</ul>
|
|
</div>
|
|
<a name="skip-navbar_bottom">
|
|
<!-- -->
|
|
</a></div>
|
|
<!-- ======== END OF BOTTOM NAVBAR ======= -->
|
|
</body>
|
|
</html>
|