Ejemplo n.º 1
0
        public override void HandlePacket(ecProto.ecPacket packet)
        {
            ECOpCodes op = packet.Opcode();

            switch (op)
            {
            case ECOpCodes.EC_OP_STATS:
                m_owner.StatsReplyInvoke(packet);
                break;

            case ECOpCodes.EC_OP_DLOAD_QUEUE:
                m_owner.DloadQueueReply(packet);
                break;

            case ECOpCodes.EC_OP_SHARED_FILES:
                m_owner.SharedFilesReply(packet);
                break;

            case ECOpCodes.EC_OP_NOOP:
                break;

            default:
                throw new Exception("Unhandled EC reply");
            }
        }
Ejemplo n.º 2
0
 public override void HandlePacket(ecProto.ecPacket packet)
 {
     if (packet.Opcode() == ECOpCodes.EC_OP_AUTH_OK)
     {
         Console.WriteLine("amuleLogicHandler : Authenticated OK");
         m_auth_result = true;
         m_owner.m_packet_op_Done.Set();
     }
     else
     {
         Console.WriteLine("amuleLogicHandler : Authentication failed. Core reply was {0}", packet.Opcode());
     }
 }