⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 sharecontent.cs

📁 破解的飞信源代码
💻 CS
📖 第 1 页 / 共 2 页
字号:
                return this._finishPercent;
            }
            set
            {
                this._finishPercent = value;
            }
        }

        public string First100MMd5
        {
            get
            {
                return this._first100MMd5;
            }
            set
            {
                this._first100MMd5 = value;
            }
        }

        public string Id
        {
            get
            {
                return this._id;
            }
            set
            {
                this._id = value;
            }
        }

        public bool IsCancel
        {
            get
            {
                return this._isCancel;
            }
            set
            {
                this._isCancel = value;
            }
        }

        public bool IsClosed
        {
            get
            {
                return this._isClosed;
            }
            internal set
            {
                this._isClosed = value;
            }
        }

        public bool IsFailed
        {
            get
            {
                return this._isFailed;
            }
            internal set
            {
                this._isFailed = value;
            }
        }

        public bool IsOnce
        {
            get
            {
                return (this.FileSize < base.Owner.Configuration.SystemSetting.FileShareSetting.OnceUploadSize);
            }
        }

        public long LastTimeCompleteSize
        {
            get
            {
                return this._lastCompleteSize;
            }
            set
            {
                this._lastCompleteSize = value;
            }
        }

        public AllEndPoints MyEndPoints
        {
            get
            {
                return this._myEndPoints;
            }
            set
            {
                this._myEndPoints = value;
            }
        }

        public OtherSideOption OtherSideSharedContentOption
        {
            get
            {
                return this._otherSideOption;
            }
            set
            {
                this._otherSideOption = value;
            }
        }

        public bool P2pFailedToRelay
        {
            get
            {
                return this._p2pFailedToRelay;
            }
            set
            {
                this._p2pFailedToRelay = value;
            }
        }

        public P2PSessionFinder P2pFinder
        {
            get
            {
                return this._p2pFinder;
            }
            set
            {
                this._p2pFinder = value;
            }
        }

        public IFileTransportor P2pTransport
        {
            get
            {
                return this._p2pTransport;
            }
            set
            {
                if (value == null)
                {
                    this._p2pTransport = null;
                }
                else
                {
                    if (this._p2pTransport != null)
                    {
                        this._p2pTransport.BlockTransported -= new EventHandler<BlockTranEventArgs>(this, (IntPtr) this._p2pTransport_BlockTransported);
                        this._p2pTransport.TransportCompleted -= new EventHandler(this._p2pTransport_TransportCompleted);
                        this._p2pTransport.TransportFailed -= new EventHandler<TranFailedEventArgs>(this, (IntPtr) this._p2pTransport_TransportFailed);
                    }
                    this._p2pTransport = value;
                    this._p2pTransport.BlockTransported += new EventHandler<BlockTranEventArgs>(this, (IntPtr) this._p2pTransport_BlockTransported);
                    this._p2pTransport.TransportCompleted += new EventHandler(this._p2pTransport_TransportCompleted);
                    this._p2pTransport.TransportFailed += new EventHandler<TranFailedEventArgs>(this, (IntPtr) this._p2pTransport_TransportFailed);
                }
            }
        }

        public string PreviewImageBase64String
        {
            get
            {
                return this._previewImageBase64String;
            }
            internal set
            {
                this._previewImageBase64String = value;
            }
        }

        public Imps.Client.Core.P2P.ICE.PunchingResult PunchingResult
        {
            get
            {
                return this._punchingResult;
            }
            internal set
            {
                this._punchingResult = value;
            }
        }

        public float Rate
        {
            get
            {
                float rate;
                if ((this.Transmittype == ShareContentTransmitType.P2P) && (this.P2pTransport != null))
                {
                    rate = this.P2pTransport.Rate;
                }
                else
                {
                    rate = this._rate;
                }
                if (rate >= 0f)
                {
                    return rate;
                }
                return 0f;
            }
            internal set
            {
                this._rate = value;
            }
        }

        public Peer RemotePeer
        {
            get
            {
                return this._peer;
            }
            set
            {
                this._peer = value;
            }
        }

        public string SessionId
        {
            get
            {
                return this._sessionId;
            }
            internal set
            {
                this._sessionId = value;
            }
        }

        public bool Start
        {
            get
            {
                return this._start;
            }
            internal set
            {
                this._start = value;
            }
        }

        public DateTime StartTime
        {
            get
            {
                return this._startTime;
            }
        }

        internal Socket TcpListener
        {
            get
            {
                return this._tcpListener;
            }
        }

        internal Socket TcpP2PSocket
        {
            get
            {
                return this._tcpP2PSocket;
            }
            set
            {
                this._tcpP2PSocket = value;
                if ((this._tcpP2PSocket != null) && this._tcpP2PSocket.Connected)
                {
                    this._p2pFinder.CanStop = true;
                }
            }
        }

        public ShareContentTransmitType Transmittype
        {
            get
            {
                return this._transmittype;
            }
            internal set
            {
                this._transmittype = value;
            }
        }

        public Imps.Client.Core.P2P.FileTransportor.TransportingFile TransportingFile
        {
            get
            {
                return this._transportingFile;
            }
            internal set
            {
                this._transportingFile = value;
                if (this.P2pTransport != null)
                {
                    this.P2pTransport.TargetFile = this._transportingFile;
                }
            }
        }

        public int TryCount
        {
            get
            {
                return this._tryCount;
            }
            internal set
            {
                this._tryCount = value;
            }
        }

        internal AutoResetEvent WaitEvent
        {
            get
            {
                return this._waitEvent;
            }
        }

        public class OtherSideOption
        {
            private AllEndPoints _endPorints;
            private string _id = string.Empty;
            private string _modes = string.Empty;
            private string _port = string.Empty;
            private bool _supportBlock;
            private bool _supportP2P;
            private bool _supportP2PV2;
            private bool _supportRelay;
            private bool _supportRelayV2;
            private int? maxSize;

            public AllEndPoints EndPorints
            {
                get
                {
                    return this._endPorints;
                }
                set
                {
                    this._endPorints = value;
                }
            }

            public string Id
            {
                get
                {
                    return this._id;
                }
                set
                {
                    this._id = value;
                }
            }

            public int? MaxSize
            {
                get
                {
                    return this.maxSize;
                }
                set
                {
                    this.maxSize = value;
                }
            }

            public string Modes
            {
                get
                {
                    return this._modes;
                }
                set
                {
                    this._modes = value;
                    string[] textArray = this._modes.ToLower().Split(new char[] { ';' });
                    if (Array.IndexOf<string>(textArray, ShareContent.GetTransmitType(ShareContentTransmitType.Relay)) > -1)
                    {
                        this._supportRelay = true;
                    }
                    if (Array.IndexOf<string>(textArray, ShareContent.GetTransmitType(ShareContentTransmitType.Block)) > -1)
                    {
                        this._supportBlock = true;
                    }
                    if (Array.IndexOf<string>(textArray, ShareContent.GetTransmitType(ShareContentTransmitType.P2P)) > -1)
                    {
                        this._supportP2P = true;
                    }
                    if (Array.IndexOf<string>(textArray, "p2pv2") > -1)
                    {
                        this._supportP2PV2 = true;
                    }
                    if (Array.IndexOf<string>(textArray, "relayv2") > -1)
                    {
                        this._supportRelayV2 = true;
                    }
                }
            }

            public string Port
            {
                get
                {
                    return this._port;
                }
                set
                {
                    this._port = value;
                }
            }

            public bool SupportBlock
            {
                get
                {
                    return this._supportBlock;
                }
                set
                {
                    this._supportBlock = value;
                }
            }

            public bool SupportP2P
            {
                get
                {
                    return this._supportP2P;
                }
                set
                {
                    this._supportP2P = value;
                }
            }

            public bool SupportP2PV2
            {
                get
                {
                    return this._supportP2PV2;
                }
                set
                {
                    this._supportP2PV2 = value;
                }
            }

            public bool SupportRelay
            {
                get
                {
                    return this._supportRelay;
                }
                set
                {
                    this._supportRelay = value;
                }
            }

            public bool SupportRelayV2
            {
                get
                {
                    return this._supportRelayV2;
                }
                set
                {
                    this._supportRelayV2 = value;
                }
            }
        }
    }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -