cohtml.StreamReader
Class responsible for reading resource stream requests.
Inherits from cohtml.Net.UnitySyncStreamReader, cohtml.Net.ISyncStreamReader, cohtml.Net.IStreamReader, SystemIDisposable
Public Functions
Section titled “Public Functions”| Name | |
|---|---|
| StreamReader(string path) Creates a StreamReader and a FileStream object with the given path. | |
| virtual override void | Close() Closes the FileStream and disposes the StreamReader. |
| virtual override uint | GetSize() Returns the size of the FileStream or the provided bytes array of a file. |
| override uint | Read(uint offset, IntPtr buffer, uint count) Reads an amount of bytes from the stream and writes the data in a given buffer. |
| UnitySyncStreamReader | OpenStreamReader(string path) Opens the file as StreamReader at the provided path if it exists. |
Additional inherited members
Section titled “Additional inherited members”Public Functions inherited from cohtml.Net.UnitySyncStreamReader
| Name | |
|---|---|
| virtual override void | Dispose() |
| UnitySyncStreamReader() | |
| delegate uint | SwigDelegateUnitySyncStreamReader_0(global.System.IntPtr swigId) |
| delegate uint | SwigDelegateUnitySyncStreamReader_1(uint offset, global.System.IntPtr buffer, uint count, global.System.IntPtr swigId) |
| delegate void | SwigDelegateUnitySyncStreamReader_2(global.System.IntPtr swigId) |
Public Functions inherited from cohtml.Net.ISyncStreamReader
| Name | |
|---|---|
| virtual override void | Dispose() |
Public Functions inherited from cohtml.Net.IStreamReader
| Name | |
|---|---|
| virtual void | Dispose() |
Protected Attributes inherited from cohtml.Net.IStreamReader
| Name | |
|---|---|
| bool | swigCMemOwn |
Public Functions Documentation
Section titled “Public Functions Documentation”function StreamReader
Section titled “function StreamReader”StreamReader( string path)Creates a StreamReader and a FileStream object with the given path.
function Close
Section titled “function Close”virtual override void Close()Closes the FileStream and disposes the StreamReader.
Reimplements: cohtml.Net.UnitySyncStreamReader.Close
function GetSize
Section titled “function GetSize”virtual override uint GetSize()Returns the size of the FileStream or the provided bytes array of a file.
Reimplements: cohtml.Net.UnitySyncStreamReader.GetSize
function Read
Section titled “function Read”override uint Read( uint offset, IntPtr buffer, uint count)Reads an amount of bytes from the stream and writes the data in a given buffer.
Parameters:
- offset Offset of the data.
- buffer A buffer to copy data to.
- count The amount of bytes to read.
function OpenStreamReader
Section titled “function OpenStreamReader”static UnitySyncStreamReader OpenStreamReader( string path)Opens the file as StreamReader at the provided path if it exists.
Parameters:
- path The path to the file.
Return: A UnitySyncStreamReader object at the provided path.
© 2026 Coherent Labs. All rights reserved.