コード例 #1
0
        protected Task StartSTATask(Action func)
        {
            label_1 :
            int num1 = 786247874;
            Task task;

            while (true)
            {
                int    num2 = 1229466523;
                uint   num3;
                Thread thread;
                Action func1;
                TaskCompletionSource <object> tcs;
                switch ((num3 = (uint)(num1 ^ num2)) % 8U)
                {
                case 0:
                    ManagerBase.\u206D‪‌‎​‏‭‮‭‍‎‏‎‬‭‌​‎‏‎‪‬‍‏​‮(thread);
                    num1 = (int)num3 * 587742219 ^ -1392086544;
                    continue;

                case 1:
                    func1 = func;
                    num1  = (int)num3 * -287062011 ^ -1206169710;
                    continue;

                case 2:
                    num1 = (int)num3 * 989351899 ^ 1418722637;
                    continue;

                case 3:
                    task = (Task)tcs.get_Task();
                    num1 = (int)num3 * -1876050536 ^ -1061438331;
                    continue;

                case 4:
                    tcs    = new TaskCompletionSource <object>();
                    thread = ManagerBase.\u200C‌‮‫‫‏‌‭‏​​‫‭‮‍‏‌‎‍‮​‏‮((ThreadStart)(() =>
                    {
                        try
                        {
                            label_2:
                            int num2 = -1253943086;
                            while (true)
                            {
                                int num3 = -1267960905;
                                uint num4;
                                switch ((num4 = (uint)(num2 ^ num3)) % 5U)
                                {
                                case 0:
                                    goto label_2;

                                case 1:
                                    func1.Invoke();
                                    tcs.SetResult((object)null);
                                    num2 = (int)num4 * 229725413 ^ -2069505776;
                                    continue;

                                case 2:
                                    num2 = (int)num4 * -68265399 ^ 1367051159;
                                    continue;

                                case 3:
                                    num2 = (int)num4 * -1131047697 ^ 534124723;
                                    continue;

                                case 4:
                                    goto label_15;

                                default:
                                    goto label_12;
                                }
                            }
                            label_12:
                            return;

                            label_15:;
                        }
                        catch (Exception ex)
                        {
                            label_10:
                            int num2 = -1645652178;
                            while (true)
                            {
                                int num3 = -1267960905;
                                uint num4;
                                switch ((num4 = (uint)(num2 ^ num3)) % 4U)
                                {
                                case 0:
                                    tcs.SetException(ex);
                                    num2 = (int)num4 * -295926253 ^ -1484353756;
                                    continue;

                                case 1:
                                    num2 = (int)num4 * -168581484 ^ 1190245955;
                                    continue;

                                case 2:
                                    goto label_10;

                                case 3:
                                    goto label_8;

                                default:
                                    goto label_4;
                                }
                            }
                            label_4:
                            return;

                            label_8:;
                        }
                    }));
                    ManagerBase.\u200D‎‫​‪‪‍‏‭‎​‮​‬‍‎‫‭‎‪‪‎​‏‭‍‬‮(thread, ApartmentState.STA);
                    num1 = (int)num3 * 744935025 ^ 1830199557;
                    continue;

                case 5:
                    goto label_1;

                case 6:
                    num1 = (int)num3 * -626387376 ^ -1909850324;
                    continue;

                default:
                    goto label_9;
                }
            }
label_9:
            return(task);
        }
コード例 #2
0
        internal virtual void Cancel()
        {
            object managerLock = ManagerBase.managerLock;
            bool   flag        = false;

            try
            {
                ManagerBase.\u206B​‬‎‭‏‬‬​‌‮‎‏‫​‌‭‏​‫‍‮‫‮(managerLock, ref flag);
                this.CancelRequested = true;
label_2:
                int num1 = -1831412988;
                while (true)
                {
                    int  num2 = -117358434;
                    uint num3;
                    switch ((num3 = (uint)(num1 ^ num2)) % 3U)
                    {
                    case 0:
                        goto label_9;

                    case 1:
                        num1 = (int)num3 * 1884983218 ^ -1632133522;
                        continue;

                    case 2:
                        goto label_2;

                    default:
                        goto label_5;
                    }
                }
label_5:
                return;

                label_9 :;
            }
            finally
            {
                if (flag)
                {
                    label_7 :
                    int num1 = -1218904226;
                    while (true)
                    {
                        int  num2 = -117358434;
                        uint num3;
                        switch ((num3 = (uint)(num1 ^ num2)) % 3U)
                        {
                        case 1:
                            ManagerBase.\u202D‭‪‏‎‮‬‫​‬‭‏​‭‪‭‏‮​‫‎​‏‭‍‌‍‬‮‮(managerLock);
                            num1 = (int)num3 * -2142364593 ^ -2085084569;
                            continue;

                        case 2:
                            goto label_7;

                        default:
                            goto label_11;
                        }
                    }
                }
                label_11 :;
            }
        }