コード例 #1
0
 public static NetworkChannel.DataEncodingScheme VerifyDataEncoding(NetworkChannel.DataEncodingScheme requestedEncoding)
 {
     if (requestedEncoding >= NetworkChannel.DataEncodingScheme.LastIndex)
     {
         requestedEncoding = NetworkChannel.DataEncodingScheme.Uncompressed;
     }
     return(requestedEncoding);
 }
コード例 #2
0
        public void Execute()
        {
            NetworkChannel.DataEncodingScheme dataEncodingScheme = NetworkChannel.VerifyDataEncoding(this.m_requestedEncoding);
            base.Channel.SetEncoding(dataEncodingScheme);
            NetworkChannelCompressionReply networkChannelCompressionReply = new NetworkChannelCompressionReply(base.Channel, dataEncodingScheme);

            networkChannelCompressionReply.Send();
            base.Channel.KeepAlive = true;
        }
コード例 #3
0
 // Token: 0x060017B1 RID: 6065 RVA: 0x00061EC5 File Offset: 0x000600C5
 internal NetworkChannelFileTransferReply(NetworkChannel channel, NetworkChannelMessage.MessageType msgType, byte[] packetContent) : base(channel, msgType, packetContent)
 {
     this.FileSize     = base.Packet.ExtractInt64();
     this.LastWriteUtc = base.Packet.ExtractDateTime();
     this.DataEncoding = (NetworkChannel.DataEncodingScheme)base.Packet.ExtractUInt32();
 }
コード例 #4
0
 internal NetworkChannelCompressionReply(NetworkChannel channel, NetworkChannel.DataEncodingScheme acceptedEncoding) : base(channel, NetworkChannelMessage.MessageType.CompressionReply)
 {
     this.m_acceptedEncoding = acceptedEncoding;
 }
コード例 #5
0
 internal void SetEncoding(NetworkChannel.DataEncodingScheme scheme)
 {
     this.m_transport.Encoding = scheme;
     ExTraceGlobals.NetworkChannelTracer.TraceDebug <NetworkChannel.DataEncodingScheme>((long)this.GetHashCode(), "Compression selected: {0}", scheme);
 }
コード例 #6
0
 internal NetworkChannelCompressionRequest(NetworkChannel channel, NetworkChannel.DataEncodingScheme requestedEncoding) : base(channel, NetworkChannelMessage.MessageType.CompressionRequest)
 {
     this.m_requestedEncoding = requestedEncoding;
 }