本文整理汇总了C#中System.IO.BinaryReader.reset方法的典型用法代码示例。如果您正苦于以下问题:C# System.IO.BinaryReader.reset方法的具体用法?C# System.IO.BinaryReader.reset怎么用?C# System.IO.BinaryReader.reset使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.IO.BinaryReader
的用法示例。
在下文中一共展示了System.IO.BinaryReader.reset方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: isSwf
public static bool isSwf(System.IO.Stream in_Renamed)
{
try
{
//UPGRADE_TODO: Class 'java.io.DataInputStream' was converted to 'System.IO.BinaryReader' which has a different behavior. "ms-help://MS.VSCC.v80/dv_commoner/local/redirect.htm?index='!DefaultContextWindowIndex'&keyword='jlca1073_javaioDataInputStream'"
System.IO.BinaryReader data = new System.IO.BinaryReader(in_Renamed);
sbyte[] b = new sbyte[3];
//UPGRADE_ISSUE: Method 'java.io.FilterInputStream.mark' was not converted. "ms-help://MS.VSCC.v80/dv_commoner/local/redirect.htm?index='!DefaultContextWindowIndex'&keyword='jlca1000_javaioFilterInputStreammark_int'"
data.mark(b.Length);
SupportClass.ReadInput(data.BaseStream, b, 0, b.Length);
if (b[0] == 'C' && b[1] == 'W' && b[2] == 'S' || b[0] == 'F' && b[1] == 'W' && b[2] == 'S')
{
//UPGRADE_ISSUE: Method 'java.io.FilterInputStream.reset' was not converted. "ms-help://MS.VSCC.v80/dv_commoner/local/redirect.htm?index='!DefaultContextWindowIndex'&keyword='jlca1000_javaioFilterInputStreamreset'"
data.reset();
return true;
}
else
{
//UPGRADE_ISSUE: Method 'java.io.FilterInputStream.reset' was not converted. "ms-help://MS.VSCC.v80/dv_commoner/local/redirect.htm?index='!DefaultContextWindowIndex'&keyword='jlca1000_javaioFilterInputStreamreset'"
data.reset();
return false;
}
}
catch (System.IO.IOException e)
{
return false;
}
}