Here are the examples of the csharp api System.IO.Stream.ReadChar() taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.
2 Examples
19
Source : StreamExtensions.cs
with MIT License
from Greavesy1899
with MIT License
from Greavesy1899
public static char[] ReadChars(this Stream stream, int size)
{
char[] data = new char[size];
for (int i = 0; i < size; i++)
{
data[i] = stream.ReadChar();
}
return data;
}
19
Source : StreamExtensions.cs
with MIT License
from Greavesy1899
with MIT License
from Greavesy1899
public static string ReadString(this Stream stream)
{
string newString = "";
while (stream.PeekChar() != '\0')
{
newString += stream.ReadChar();
}
stream.ReadByte();
return newString;
}