Ejemplo n.º 1
0
        private static bool OnGetInstanceListResponse(ByteArray byteArray, IDeamonClientService clientService)
        {
            AppInstanceSequence instances = new AppInstanceSequence();

            instances.ReadFromByteArray(byteArray);

            int crc = byteArray.readIntNCRC();

            if (crc == byteArray.CRC)
            {
                clientService.OnGetInstanceListResponse(ref instances);
            }

            byteArray.Recycle();
            return(true);
        }
Ejemplo n.º 2
0
        private static string ParseGetInstanceListResponse(ByteArray byteArray)
        {
            StringBuilder sb = new StringBuilder();

            sb.Append("GetInstanceListResponse(");

            sb.Append("instances : AppInstanceSequence");

            sb.Append(")\r\n{\r\n");
            int crc = byteArray.readIntNCRC(); // parse global seq
            AppInstanceSequence instances = new AppInstanceSequence();

            instances.ReadFromByteArray(byteArray);
            sb.AppendFormat(@"instances = ""{0}""", instances);
            sb.Append("}");
            return(sb.ToString());
        }