Пример #1
0
 private static long \uE001(Stream \uE021, int \uE022)
 {
     \uE022 = ((\uE022 > CpInazumaMsgPack.\uE001) ? CpInazumaMsgPack.\uE001 : \uE022);
     byte[] array = new byte[\uE022];
     \uE021.Read(array, 0, \uE022);
     Array.Clear(CpInazumaMsgPack.\uE008, 0, CpInazumaMsgPack.\uE008.Length);
     CpInazumaMsgPack.\uE000(array).CopyTo(CpInazumaMsgPack.\uE008, 0);
     return(BitConverter.ToInt64(CpInazumaMsgPack.\uE008, 0));
 }
Пример #2
0
        private static void \uE019(byte[] \uE047, Stream \uE048)
        {
            int num = \uE047.Length;

            if (CpInazumaMsgPack.\uE005 == CpCustomDataPackMode.Older)
            {
                \uE048.WriteByte(219);
                \uE048.Write(CpInazumaMsgPack.\uE000(BitConverter.GetBytes(num)), 0, 4);
            }
            else
            {
                CpInazumaMsgPack.\uE00B(num, CpInazumaMsgPack.\uE009(num), \uE048);
            }
            \uE048.Write(\uE047, 0, \uE047.Length);
        }
Пример #3
0
        private static void \uE018(string \uE045, Stream \uE046)
        {
            byte[] bytes = CpInazumaMsgPack.\uE000.GetBytes(\uE045);
            int    num   = bytes.Length;

            if (CpInazumaMsgPack.\uE005 == CpCustomDataPackMode.Older)
            {
                \uE046.WriteByte(219);
                \uE046.Write(CpInazumaMsgPack.\uE000(BitConverter.GetBytes(num)), 0, 4);
            }
            else
            {
                CpInazumaMsgPack.\uE00B(num, CpInazumaMsgPack.\uE008(num), \uE046);
            }
            \uE046.Write(bytes, 0, bytes.Length);
        }
Пример #4
0
        private static void \uE016(IList \uE041, Stream \uE042)
        {
            int count = \uE041.Count;

            if (CpInazumaMsgPack.\uE005 == CpCustomDataPackMode.Older)
            {
                \uE042.WriteByte(221);
                \uE042.Write(CpInazumaMsgPack.\uE000(BitConverter.GetBytes(count)), 0, 4);
            }
            else
            {
                CpInazumaMsgPack.\uE00B(\uE041.Count, CpInazumaMsgPack.\uE007(count), \uE042);
            }
            for (int i = 0; i < count; i++)
            {
                CpInazumaMsgPack.Pack(\uE041[i], \uE042);
            }
        }
Пример #5
0
        private static void \uE017(IDictionary \uE043, Stream \uE044)
        {
            int count = \uE043.Count;

            if (CpInazumaMsgPack.\uE005 == CpCustomDataPackMode.Older)
            {
                \uE044.WriteByte(223);
                \uE044.Write(CpInazumaMsgPack.\uE000(BitConverter.GetBytes(count)), 0, 4);
            }
            else
            {
                CpInazumaMsgPack.\uE00B(count, CpInazumaMsgPack.\uE006(count), \uE044);
            }
            foreach (object obj in \uE043)
            {
                DictionaryEntry dictionaryEntry = (DictionaryEntry)obj;
                CpInazumaMsgPack.Pack(dictionaryEntry.Key, \uE044);
                CpInazumaMsgPack.Pack(dictionaryEntry.Value, \uE044);
            }
        }
Пример #6
0
        private static void \uE00B(object \uE030, \uE015 \uE031, Stream \uE032)
        {
            if (\uE031 <= global::\uE015.\uE002)
            {
                if (\uE031 == global::\uE015.\uE000)
                {
                    ulong num = Convert.ToUInt64(\uE030);
                    \uE032.WriteByte(Convert.ToByte(num & 255UL));
                    return;
                }
                if (\uE031 != global::\uE015.\uE002)
                {
                    return;
                }
            }
            else if (\uE031 != global::\uE015.\uE003)
            {
                switch (\uE031)
                {
                case global::\uE015.\uE004:
                    \uE032.WriteByte((byte)(\uE031 | (\uE015)(Convert.ToByte(\uE030) & 31)));
                    return;

                case (\uE015)161:
                case (\uE015)162:
                case (\uE015)163:
                case (\uE015)164:
                case (\uE015)165:
                case (\uE015)166:
                case (\uE015)167:
                case (\uE015)168:
                case (\uE015)169:
                case (\uE015)170:
                case (\uE015)171:
                case (\uE015)172:
                case (\uE015)173:
                case (\uE015)174:
                case (\uE015)175:
                case (\uE015)176:
                case (\uE015)177:
                case (\uE015)178:
                case (\uE015)179:
                case (\uE015)180:
                case (\uE015)181:
                case (\uE015)182:
                case (\uE015)183:
                case (\uE015)184:
                case (\uE015)185:
                case (\uE015)186:
                case (\uE015)187:
                case (\uE015)188:
                case (\uE015)189:
                case (\uE015)190:
                case (\uE015)191:
                case global::\uE015.\uE00B:
                    break;

                case global::\uE015.\uE00A:
                case global::\uE015.\uE00C:
                case global::\uE015.\uE00D:
                    \uE032.WriteByte((byte)\uE031);
                    return;

                case global::\uE015.\uE00E:
                case global::\uE015.\uE011:
                case global::\uE015.\uE016:
                case global::\uE015.\uE005:
                case global::\uE015.\uE006:
                case global::\uE015.\uE007:
                case global::\uE015.\uE008:
                case global::\uE015.\uE009:
                case global::\uE015.\uE01E:
                    \uE032.WriteByte((byte)\uE031);
                    \uE032.WriteByte(Convert.ToByte(\uE030));
                    return;

                case global::\uE015.\uE00F:
                case global::\uE015.\uE012:
                case global::\uE015.\uE017:
                case global::\uE015.\uE01F:
                case global::\uE015.\uE021:
                case global::\uE015.\uE023:
                    \uE032.WriteByte((byte)\uE031);
                    \uE032.Write(CpInazumaMsgPack.\uE000(BitConverter.GetBytes(Convert.ToUInt16(\uE030))), 0, 2);
                    return;

                case global::\uE015.\uE010:
                case global::\uE015.\uE013:
                case global::\uE015.\uE018:
                case global::\uE015.\uE020:
                case global::\uE015.\uE022:
                case global::\uE015.\uE024:
                    \uE032.WriteByte((byte)\uE031);
                    \uE032.Write(CpInazumaMsgPack.\uE000(BitConverter.GetBytes(Convert.ToUInt32(\uE030))), 0, 4);
                    return;

                case global::\uE015.\uE014:
                    \uE032.WriteByte((byte)\uE031);
                    \uE032.Write(CpInazumaMsgPack.\uE000(BitConverter.GetBytes(Convert.ToSingle(\uE030))), 0, 4);
                    return;

                case global::\uE015.\uE015:
                    \uE032.WriteByte((byte)\uE031);
                    \uE032.Write(CpInazumaMsgPack.\uE000(BitConverter.GetBytes(Convert.ToDouble(\uE030))), 0, 8);
                    return;

                case global::\uE015.\uE019:
                    \uE032.WriteByte((byte)\uE031);
                    \uE032.Write(CpInazumaMsgPack.\uE000(BitConverter.GetBytes(Convert.ToUInt64(\uE030))), 0, 8);
                    return;

                case global::\uE015.\uE01A:
                    \uE032.WriteByte((byte)\uE031);
                    \uE032.Write(CpInazumaMsgPack.\uE000(BitConverter.GetBytes((short)Convert.ToSByte(\uE030))), 0, 1);
                    return;

                case global::\uE015.\uE01B:
                    \uE032.WriteByte((byte)\uE031);
                    \uE032.Write(CpInazumaMsgPack.\uE000(BitConverter.GetBytes(Convert.ToInt16(\uE030))), 0, 2);
                    return;

                case global::\uE015.\uE01C:
                    \uE032.WriteByte((byte)\uE031);
                    \uE032.Write(CpInazumaMsgPack.\uE000(BitConverter.GetBytes(Convert.ToInt32(\uE030))), 0, 4);
                    return;

                case global::\uE015.\uE01D:
                    \uE032.WriteByte((byte)\uE031);
                    \uE032.Write(CpInazumaMsgPack.\uE000(BitConverter.GetBytes(Convert.ToInt64(\uE030))), 0, 8);
                    break;

                case global::\uE015.\uE001:
                {
                    long num2 = Convert.ToInt64(\uE030);
                    \uE032.WriteByte(Convert.ToByte(num2 & 255L));
                    return;
                }

                default:
                    return;
                }
                return;
            }
            \uE032.WriteByte((byte)(\uE031 | (\uE015)(Convert.ToByte(\uE030) & 15)));
        }
Пример #7
0
 private static double \uE003(Stream \uE024)
 {
     byte[] array = new byte[8];
     \uE024.Read(array, 0, 8);
     return(BitConverter.ToDouble(CpInazumaMsgPack.\uE000(array), 0));
 }
Пример #8
0
 private static float \uE002(Stream \uE023)
 {
     byte[] array = new byte[4];
     \uE023.Read(array, 0, 4);
     return(BitConverter.ToSingle(CpInazumaMsgPack.\uE000(array), 0));
 }