示例#1
0
 public void method_0(string string_0, int int_0, Interface26 interface26_0, P2PSessionMessageTypeRoom p2PSessionMessageTypeRoom_1)
 {
     this.object_0 = interface26_0;
     this.p2PSessionMessageTypeRoom_0 = p2PSessionMessageTypeRoom_1;
     this.bool_0 = this.object_0.imethod_4() == string_0;
     this.method_1();
 }
示例#2
0
    private void method_3(string string_1, AgileIPE agileIPE_0, bool bool_0)
    {
        Interface26 interface2 = Class157.CreateInterface26(this.object_0.imethod_1());

        try
        {
            interface2.SetStreamContract(this.object_0.GetStreamContract());
            interface2.SetAgileLogger(this.object_0.GetAgileLogger());
            interface2.imethod_10(this.object_0.imethod_9());
            interface2.imethod_12(this.object_0.imethod_11());
            interface2.imethod_8(this.object_0.imethod_7());
            interface2.SocketSendBuffSize = this.object_0.SocketSendBuffSize;
            interface2.imethod_23(this.object_0.imethod_22());
            interface2.LjXdpkRter(null);
            interface2.SetData(0);
            interface2.SetAgileIPE(agileIPE_0);
            interface2.AutoReconnect = false;
            interface2.Initialize();
            interface2.ConnectionInterrupted += new CbGeneric(this.newEngine_ConnectionInterrupted);
            this.safeDictionary_0.Add(string_1, interface2);
            this.SomeOneConnected(string_1, interface2.GetAgileIPE().IPEndPoint_0, bool_0);
        }
        catch (Exception)
        {
            interface2.Dispose();
        }
    }
示例#3
0
 private void newEngine_ConnectionInterrupted()
 {
     try
     {
         List <string> list = new List <string>();
         foreach (string str in this.safeDictionary_0.GetKeyList())
         {
             Interface26 interface2 = this.safeDictionary_0.Get(str);
             if (!((interface2 == null) || interface2.Connected))
             {
                 list.Add(str);
             }
         }
         foreach (string str in list)
         {
             this.safeDictionary_0.Remove(str);
         }
         foreach (string str in list)
         {
             //    this.XppbFuVvfm(str);
         }
     }
     catch (Exception exception)
     {
         this.iagileLogger_0.Log(exception, "OMCS.Communication.Plus.Application.P2PSession.Passive.Tcp.OutConnectionManager.newEngine_ConnectionInterrupted", ErrorLevel.Standard);
     }
 }
示例#4
0
    public void CoNbnqugPr(string string_1, IMessageHandler interface37, bool bool_0, ActionTypeOnChannelIsBusy actionTypeOnChannelIsBusy)
    {
        Interface26 interface2 = this.safeDictionary_0.Get(string_1);

        if (interface2 != null)
        {
            interface2.CommitMessageToServer(interface37, bool_0, actionTypeOnChannelIsBusy);
        }
    }
示例#5
0
    public bool?method_8(string string_1)
    {
        Interface26 interface2 = this.safeDictionary_0.Get(string_1);

        if (interface2 == null)
        {
            return(null);
        }
        return(new bool?(interface2.ChannelIsBusy));
    }
示例#6
0
    public void Close(string string_1)
    {
        Interface26 interface2 = this.safeDictionary_0.Get(string_1);

        if (interface2 != null)
        {
            interface2.Dispose();
            this.safeDictionary_0.Remove(string_1);
            //  this.XppbFuVvfm(string_1);
        }
    }
示例#7
0
文件: Class194.cs 项目: 15831944/WW
        protected override Polyline2D vmethod_1(ns9.Class107 edge)
        {
            Point3D     location1        = edge.StartVertex.Point.Location;
            Point3D     location2        = edge.EndVertex.Point.Location;
            Polyline2D  polyline2D       = new Polyline2D(2);
            Interface26 pointParamMapper = this.PointParamMapper;

            polyline2D.Add(pointParamMapper.imethod_0(location1));
            polyline2D.Add(pointParamMapper.imethod_0(location2));
            return(polyline2D);
        }
        internal void method_39(AttrCollection A_0, Interface26 A_1)
        {
            int num = 2;

            if (A_0 == null)
            {
                throw new ArgumentNullException(BookmarkStart.b("䰧天堫漭䐯䘱䘳䔵", num));
            }
            for (int i = 0; i < base.Count; i++)
            {
                int    num3 = base.method_18(i);
                object obj2 = base.method_19(i);
                this.method_40(A_0, num3, obj2, A_1);
            }
        }
示例#9
0
 public P2PClass(Interface26 interface26_0, P2PSessionMessageTypeRoom p2PSessionMessageTypeRoom_1, IAgileLogger iagileLogger_0)
 {
     if (cbGeneric_2 == null)
     {
         cbGeneric_2 = new CbGeneric <P2PChannelState>(P2PClass.smethod_0);
     }
     this.P2PChannelOpened += cbGeneric_2;
     if (cbGeneric_3 == null)
     {
         cbGeneric_3 = new CbGeneric <P2PChannelState>(P2PClass.smethod_1);
     }
     this.P2PChannelClosed           += cbGeneric_3;
     this.object_0                    = interface26_0;
     this.p2PSessionMessageTypeRoom_0 = p2PSessionMessageTypeRoom_1;
     this.emptyAgileLogger_0          = (EmptyAgileLogger)iagileLogger_0;
 }
示例#10
0
 public UdpChannelManager(AgileIPE agileIPE_2, Interface26 interface26_0, P2PSessionMessageTypeRoom p2PSessionMessageTypeRoom_1, bool bool_3, IAgileLogger iagileLogger_0)
 {
     if (cbGeneric_7 == null)
     {
         cbGeneric_7 = new CbGeneric <P2PChannelState>(UdpChannelManager.smethod_0);
     }
     this.P2PChannelOpened += cbGeneric_7;
     if (cbGeneric_8 == null)
     {
         cbGeneric_8 = new CbGeneric <P2PChannelState>(UdpChannelManager.smethod_1);
     }
     this.P2PChannelClosed           += cbGeneric_8;
     this.agileIPE_0                  = agileIPE_2;
     this.object_0                    = interface26_0;
     this.p2PSessionMessageTypeRoom_0 = p2PSessionMessageTypeRoom_1;
     this.bool_1             = bool_3;
     this.emptyAgileLogger_0 = (EmptyAgileLogger)iagileLogger_0;
 }
示例#11
0
        protected override Polyline2D vmethod_1(ns9.Class107 edge)
        {
            Point3D    location1  = edge.StartVertex.Point.Location;
            Point3D    location2  = edge.EndVertex.Point.Location;
            Polyline2D polyline2D = new Polyline2D(2);

            if (location1 == location2 && this.double_2 != 0.0)
            {
                Point3D  point3D1 = new Point3D(this.class247_0.Position);
                double   length   = this.class247_0.MajorAxis.GetLength();
                Vector3D normal   = this.class247_0.Normal;
                normal.Normalize();
                Point3D point3D2 = point3D1 - normal * (length / System.Math.Tan(this.double_2));
                if ((point3D2 - location1).GetLength() < 0.0001 * length)
                {
                    double x1 = Vector3D.DotProduct(point3D2 - point3D1, normal) / System.Math.Cos(this.double_2);
                    if (this.class690_0.Value)
                    {
                        double x2 = -x1;
                        polyline2D.Add(new Point2D(x2, 2.0 * System.Math.PI));
                        polyline2D.Add(new Point2D(x2, 4.0 * System.Math.PI / 3.0));
                        polyline2D.Add(new Point2D(x2, 2.0 * System.Math.PI / 3.0));
                        polyline2D.Add(new Point2D(x2, 0.0));
                    }
                    else
                    {
                        polyline2D.Add(new Point2D(x1, 0.0));
                        polyline2D.Add(new Point2D(x1, 2.0 * System.Math.PI / 3.0));
                        polyline2D.Add(new Point2D(x1, 4.0 * System.Math.PI / 3.0));
                        polyline2D.Add(new Point2D(x1, 2.0 * System.Math.PI));
                    }
                    return(polyline2D);
                }
            }
            Interface26 pointParamMapper = this.PointParamMapper;

            polyline2D.Add(pointParamMapper.imethod_0(location1));
            polyline2D.Add(pointParamMapper.imethod_0(location2));
            return(polyline2D);
        }
        private void method_40(AttrCollection A_0, int A_1, object A_2, Interface26 A_3)
        {
            object obj2;

            if (A_2 is Interface31)
            {
                Interface31 interface2 = (Interface31)A_2;
                if (interface2.imethod_0())
                {
                    return;
                }
                if (interface2 is Interface33)
                {
                    Interface33 interface3 = (Interface33)A_0[A_1];
                    obj2 = ((Interface33)interface2).imethod_2(interface3);
                }
                else
                {
                    obj2 = interface2.imethod_1();
                }
            }
            else if (A_2 is Class650)
            {
                obj2 = ((Class650)A_2).method_3(A_0, A_1);
            }
            else
            {
                obj2 = A_2;
            }
            if (A_3 != null)
            {
                A_3.imethod_0(A_0, A_1, obj2);
            }
            else
            {
                A_0[A_1] = obj2;
            }
        }
示例#13
0
 public TcpPassiveEngine(Interface26 interface26_0, IBasicOutter ibasicOutter_1, IAgileLogger iagileLogger_1)
 {
     this.object_0       = interface26_0;
     this.ibasicOutter_0 = ibasicOutter_1;
     this.iagileLogger_0 = iagileLogger_1;
 }
示例#14
0
 public void SetEngine(IEngine interface3_0)
 {
     this.interface26_0 = interface3_0 as Interface26;
 }
示例#15
0
 protected override void vmethod_0(Class608 wires, Polygon2D[] paramShape, Interface26 mapper)
 {
 }
示例#16
0
 public void method_0(string string_1, Interface26 interface26_0, IAgileLogger iagileLogger_1)
 {
     this.string_0       = string_1;
     this.object_0       = interface26_0;
     this.iagileLogger_0 = iagileLogger_1;
 }
示例#17
0
文件: Class188.cs 项目: 15831944/WW
        public virtual void vmethod_2(Class95 firstLoop, Class608 wires)
        {
            Interface26 pointParamMapper = this.PointParamMapper;

            if (pointParamMapper != null)
            {
                List <Polygon2D> polygon2DList1 = new List <Polygon2D>();
                List <Polygon2D> polygon2DList2 = new List <Polygon2D>();
                foreach (Class95 loop in (IEnumerable <Class95>)Class80.smethod_0 <Class95>(firstLoop))
                {
                    Class917  approximation = new Class917();
                    Polygon2D polygon2D1    = new Polygon2D();
                    foreach (ns9.Class107 coedge in (IEnumerable <ns9.Class107>)loop.Coedges)
                    {
                        ns9.Class88 curve = (ns9.Class88)coedge.Edge.Curve;
                        if (curve != null)
                        {
                            curve.CurvePrimitive.imethod_3(loop, curve, coedge, approximation, wires.Accuracy);
                        }
                        else
                        {
                            Polyline2D polyline2D = this.vmethod_1(coedge);
                            polygon2D1.AddRange((IEnumerable <Point2D>)polyline2D);
                        }
                    }
                    if (polygon2D1.Count > 0)
                    {
                        if (pointParamMapper.IsRightHandedParametric)
                        {
                            if (polygon2D1.GetArea() >= 0.0)
                            {
                                polygon2DList1.Add(polygon2D1);
                            }
                            else
                            {
                                polygon2DList2.Add(polygon2D1);
                            }
                        }
                        else if (polygon2D1.GetArea() < 0.0)
                        {
                            polygon2DList1.Add(polygon2D1);
                        }
                        else
                        {
                            polygon2DList2.Add(polygon2D1);
                        }
                    }
                    Point3D[] points = approximation.Points;
                    if (points.Length > 0)
                    {
                        Polygon2D polygon2D2 = new Polygon2D(points.Length);
                        foreach (Point3D point in points)
                        {
                            polygon2D2.Add(pointParamMapper.imethod_0(point));
                        }
                        if (pointParamMapper.IsRightHandedParametric)
                        {
                            if (polygon2D2.GetArea() >= 0.0)
                            {
                                polygon2DList1.Add(polygon2D2);
                            }
                            else
                            {
                                polygon2DList2.Add(polygon2D2);
                            }
                        }
                        else if (polygon2D2.GetArea() < 0.0)
                        {
                            polygon2DList1.Add(polygon2D2);
                        }
                        else
                        {
                            polygon2DList2.Add(polygon2D2);
                        }
                    }
                }
                if (polygon2DList1.Count == 0 && polygon2DList2.Count != 0)
                {
                    foreach (List <Point2D> point2DList in polygon2DList2)
                    {
                        point2DList.Reverse();
                    }
                    polygon2DList1.AddRange((IEnumerable <Polygon2D>)polygon2DList2);
                    polygon2DList2.Clear();
                }
                Polygon2D[] paramShape = Class794.smethod_9(this.ExtendedIntervalU, this.ExtendedIntervalV, polygon2DList1.ToArray(), polygon2DList2.ToArray(), pointParamMapper.IsRightHandedParametric, wires.Accuracy.Epsilon);
                if (paramShape == null)
                {
                    return;
                }
                foreach (Polygon2D polygon2D in paramShape)
                {
                    Polygon3D polygon3D = new Polygon3D(polygon2D.Count);
                    foreach (Point2D point2D in (List <Point2D>)polygon2D)
                    {
                        polygon3D.Add(pointParamMapper.imethod_1(point2D.X, point2D.Y));
                    }
                    wires.method_9((ICollection <Point3D>)polygon3D, true);
                }
                this.vmethod_0(wires, paramShape, pointParamMapper);
            }
            else
            {
                Class80.smethod_2((Class80)firstLoop, wires);
            }
        }
示例#18
0
 public void method_0(Interface26 interface26_0)
 {
     this.object_0 = interface26_0;
 }
示例#19
0
    public LogonResponse Initialize(string userID, string logonPassword, string serverIP, int serverPort, ICustomizeHandler customizeHandler)
    {
        if (this.emptyAgileLogger_0 == null)
        {
            if (this.string_1 == null)
            {
                this.emptyAgileLogger_0 = new EmptyAgileLogger();
            }
            else
            {
                FileAgileLogger logger = new FileAgileLogger(this.string_1)
                {
                    MaxLength4ChangeFile = 0x100000L
                };
                this.emptyAgileLogger_0 = (EmptyAgileLogger)logger;
            }
        }
        this.eventSafeTrigger_0.AgileLogger = this.emptyAgileLogger_0;
        this.string_0 = logonPassword;
        Class16 class2 = new Class16();
        MessageForbiddenHandler class3 = new MessageForbiddenHandler();

        this.object_0 = Class157.CreateInterface26((Enum6)0);
        int num = (!this.advancedOptions_0.CheckResponseTTL4Query || !this.bool_4) ? 10 : 0;

        this.class72_0 = new Class72(num, this.int_1);
        this.class72_0.SetEngine((IEngine)this.object_0);
        Interface36          interface2 = new Class94((ICommitMessageToServer)this.object_0, class3, null);
        Class79              class4     = new Class79(this.class72_0, interface2);
        BasicMessageTypeRoom room       = new BasicMessageTypeRoom();

        room.Initialize();
        CustomizeMessageTypeRoom room2 = new CustomizeMessageTypeRoom();

        room2.Initialize();
        FileMessageTypeRoom room3 = new FileMessageTypeRoom();

        room3.Initialize();
        P2PSessionMessageTypeRoom room4 = new P2PSessionMessageTypeRoom();

        room4.Initialize();
        FriendsMessageTypeRoom room5 = new FriendsMessageTypeRoom();

        room5.Initialize();
        GroupMessageTypeRoom room6 = new GroupMessageTypeRoom();

        room6.Initialize();
        ContactsMessageTypeRoom room7 = new ContactsMessageTypeRoom();

        room7.Initialize();
        this.class113_0 = new BasicOutter();
        this.class113_0.SetBasicMessageTypeRoom(room);
        this.class113_0.SetActionType(class4);
        this.class113_0.SetStreamContract(class2);
        this.class113_0.SetICommitMessageToServer((ICommitMessageToServer)this.object_0);
        this.class113_0.NgadStsqsh += new CbGeneric(this.method_1);
        this.class113_0.method_2(userID);
        this.class71_0 = new Class71(this.class113_0, this.bool_4 ? 0 : this.int_0);
        Class78 class9 = new Class78();

        class9.method_5(this.class113_0);
        class9.method_1(room);
        class9.method_2(class2);
        class9.method_4((ICommitMessageToServer)this.object_0);
        class9.method_3(class4);
        this.class43_0 = new Class43();
        this.class43_0.method_5(class4);
        this.class43_0.method_4(class2);
        this.class43_0.method_3(room2);
        this.class43_0.method_1(userID);
        CustomizeProcess class10 = new CustomizeProcess();

        class10.SetStreamContractHelper(class2);
        class10.SetCustomizeHandler(customizeHandler);
        class10.SetCustomizeMessageTypeRoom(room2);
        class10.SetActionType(class4);
        class10.Event_0 += new CbGeneric <string, int, byte[], string>(this.OnMessageReceived);
        Class75 class7 = new Class75(class4, class2, room4);

        class7.method_1(userID);
        Class24 class8 = new Class24();

        class8.method_0(room4);
        class8.method_1(class2);
        class8.DaTyrcXefU(class7);
        this.class2_0 = new FileTransfering();
        this.class2_0.method_0(this.emptyAgileLogger_0);
        this.class13_0 = new FileHandler();
        this.class13_0.method_0(this.emptyAgileLogger_0);
        this.class2_0.TTL4ResumedFileItem = this.advancedOptions_0.TempFile4ResumedTTL;
        this.class13_0.method_1(class4);
        this.class13_0.method_3(class2);
        this.class13_0.imethod_1(0x100000);
        this.class13_0.method_7(this.advancedOptions_0.UseWorkThreadPool);
        this.class13_0.Initialize(userID, room3.FilePackageData);
        this.class28_0 = new Class28();
        this.class28_0.method_2(this.advancedOptions_0.CheckFileZeroSpeedSpanInSecs);
        this.class28_0.method_0(this.emptyAgileLogger_0);
        this.class28_0.method_13(room3);
        this.class28_0.method_14(class2);
        this.class28_0.method_16(class4);
        this.class28_0.method_12(this.class2_0);
        this.class28_0.method_11(this.class13_0);
        this.class28_0.Initialize(userID);
        Class70 class11 = new Class70();

        class11.method_0(room3);
        class11.method_1(class2);
        class11.method_3(this.class13_0);
        class11.method_2(this.class2_0);
        class11.method_4(this.class28_0);
        this.class126_0 = new FriendsOutter();
        this.class126_0.method_4(class4);
        this.class126_0.method_3(class2);
        this.class126_0.method_2(room5);
        this.class126_0.FriendOffline += new CbGeneric <string>(this.method_6);
        this.class126_0.method_1(userID);
        Class59 class12 = new Class59();

        class12.method_2(class2);
        class12.method_3(this.class126_0);
        class12.method_1(room5);
        this.class19_0 = new GroupOutter2();
        this.class19_0.method_0(class4);
        this.class19_0.uBkeyEkxPJ(class2);
        this.class19_0.Iibebiqvn1(room6);
        this.class19_0.SetCommitMessageToServer((ICommitMessageToServer)this.object_0);
        this.class19_0.GroupmateOffline += new CbGeneric <string>(this.method_7);
        this.class19_0.method_4(userID);
        Class140 class13 = new Class140();

        class13.method_0(room6);
        class13.method_2(this.class19_0);
        class13.method_1(class2);
        this.ContactsOutter_0 = new ContactsOutter();
        this.ContactsOutter_0.method_2(class4);
        this.ContactsOutter_0.SetStreamContract(class2);
        this.ContactsOutter_0.SetMessageType(room7);
        this.ContactsOutter_0.SetCommitMessageToServer((ICommitMessageToServer)this.object_0);
        this.ContactsOutter_0.ContactsOffline += new CbGeneric <string>(this.method_8);
        this.ContactsOutter_0.method_5(userID);
        Class20 class14 = new Class20();

        class14.SetMessageType(room7);
        class14.SetOutter(this.ContactsOutter_0);
        class14.SetStreamContract(class2);
        IProcess[] processers = new IProcess[] { class9, class10, class8, class11, class12, class13, class14 };
        this.class141_0 = new Class141(processers, this.class72_0);
        this.class141_0.method_6(this.advancedOptions_0.AsynMessageQueueEnabled && !this.bool_4);
        this.class141_0.method_7(class4);
        this.class141_0.method_4(this.emptyAgileLogger_0);
        this.class141_0.method_8();
        new Class40(new IMessageTypeRoom[] { room, room2, room3, room4, room5, room6, room7 }, this.class141_0).method_2();
        MessageDispatcher class6 = new MessageDispatcher(new Class144(new Class115(this.class141_0)), class3);

        class6.imethod_0(this.emptyAgileLogger_0);
        this.object_0.SetAgileLogger(this.emptyAgileLogger_0);
        this.object_0.Sock5ProxyInfo = this.sock5ProxyInfo_0;
        this.object_0.SetAgileIPE(new AgileIPE(serverIP, serverPort));
        this.object_0.SetStreamContract(class2);
        this.object_0.imethod_12(class6);
        this.object_0.imethod_10(GlobalUtil.MaxLengthOfMessage);
        this.object_0.AutoReconnect = false;
        this.object_0.imethod_23((this.advancedOptions_0.WriteTimeoutInSecs <= 0) ? -1 : (this.advancedOptions_0.WriteTimeoutInSecs * 0x3e8));
        this.object_0.SocketSendBuffSize           = this.advancedOptions_0.SocketSendBuffSize;
        this.object_0.UncompletedSendingCount4Busy = this.advancedOptions_0.UncompletedSendingCount4Busy;
        this.object_0.ConnectionInterrupted       += new CbGeneric(this.method_5);
        this.object_0.imethod_25(new CbGeneric(this.method_4));
        this.object_0.ConnectionRebuildStart += new CbGeneric(this.method_2);
        this.object_0.Initialize();
        LogonFullResponse response = this.class113_0.method_7(this.systemToken, this.string_0);

        if (response.LogonResult != LogonResult.Succeed)
        {
            this.object_0.OnDispose();
            return(response);
        }
        this.object_0.imethod_27();
        this.bool_0 = response.Boolean_0;
        this.bool_3 = response.GroupRelationEnabled;
        if ((this.bool_0 && this.advancedOptions_0.Boolean_0) && !this.bool_4)
        {
            if (response.UseAsP2PServer && (this.agileIPE_0 == null))
            {
                this.agileIPE_0 = new AgileIPE(this.object_0.GetAgileIPE().String_0, this.object_0.GetAgileIPE().Port + 1);
            }
            if (this.agileIPE_0 != null)
            {
                this.class58_0 = new P2PController();
                this.class58_0.method_6(this.agileIPE_0);
                this.class58_0.method_5(this.emptyAgileLogger_0);
                this.class58_0.method_3((Interface26)this.object_0);
                this.class58_0.method_2(class7);
                this.class58_0.method_4(room4);
                this.class58_0.P2PChannelClosed += new CbGeneric <P2PChannelState>(this.method_3);
                this.class58_0.method_7(userID, this.bool_2);
                interface2.imethod_2(this.class58_0);
                class8.method_2(this.class58_0);
                this.class13_0.method_4(new Class56(this.class58_0));
                this.class19_0.method_1(this.class58_0);
            }
        }
        if (this.bool_2)
        {
            this.class108_0 = new TcpPassiveEngine((Interface26)this.object_0, this.class113_0, this.emptyAgileLogger_0);
            this.class108_0.method_3();
        }
        this.class71_0.method_0();
        this.class113_0.SendHeartBeatMessage();
        this.string_3 = userID;
        this.bool_1   = true;
        this.object_0.AutoReconnect = this.bool_5;
        return(response);
    }
示例#20
0
文件: Class188.cs 项目: 15831944/WW
 protected virtual void vmethod_0(Class608 wires, Polygon2D[] paramShape, Interface26 mapper)
 {
 }