|
using System;
using System.IO;
using System.Text;
namespace Ricciolo.StylesExplorer.MarkupReflection
{
internal class BamlBinaryReader : BinaryReader
{
// Methods
public BamlBinaryReader(Stream stream)
: base(stream)
{
}
public virtual double ReadCompressedDouble()
{
switch (this.ReadByte())
{
case 1:
return 0;
case 2:
return 1;
case 3:
return -1;
case 4:
{
double num = this.ReadInt32();
return (num * 1E-06);
}
case 5:
return this.ReadDouble();
}
throw new NotSupportedException();
}
public int ReadCompressedInt32()
{
return base.Read7BitEncodedInt();
}
}
}
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.