Beispiel #1
0
    public FCells DeepCopy()
    {
        var tmp388 = new FCells();

        if ((F != null) && __isset.f)
        {
            tmp388.F = this.F.DeepCopy();
        }
        tmp388.__isset.f = this.__isset.f;
        if ((Cells != null) && __isset.cells)
        {
            tmp388.Cells = this.Cells.DeepCopy();
        }
        tmp388.__isset.cells = this.__isset.cells;
        if ((Serial_cells != null) && __isset.serial_cells)
        {
            tmp388.Serial_cells = this.Serial_cells.DeepCopy();
        }
        tmp388.__isset.serial_cells = this.__isset.serial_cells;
        return(tmp388);
    }
Beispiel #2
0
    public async global::System.Threading.Tasks.Task ReadAsync(TProtocol iprot, CancellationToken cancellationToken)
    {
        iprot.IncrementRecursionDepth();
        try
        {
            TField field;
            await iprot.ReadStructBeginAsync(cancellationToken);

            while (true)
            {
                field = await iprot.ReadFieldBeginAsync(cancellationToken);

                if (field.Type == TType.Stop)
                {
                    break;
                }

                switch (field.ID)
                {
                case 1:
                    if (field.Type == TType.Map)
                    {
                        {
                            TMap _map389 = await iprot.ReadMapBeginAsync(cancellationToken);

                            F = new Dictionary <byte[], FCells>(_map389.Count);
                            for (int _i390 = 0; _i390 < _map389.Count; ++_i390)
                            {
                                byte[] _key391;
                                FCells _val392;
                                _key391 = await iprot.ReadBinaryAsync(cancellationToken);

                                _val392 = new FCells();
                                await _val392.ReadAsync(iprot, cancellationToken);

                                F[_key391] = _val392;
                            }
                            await iprot.ReadMapEndAsync(cancellationToken);
                        }
                    }
                    else
                    {
                        await TProtocolUtil.SkipAsync(iprot, field.Type, cancellationToken);
                    }
                    break;

                case 2:
                    if (field.Type == TType.List)
                    {
                        {
                            TList _list393 = await iprot.ReadListBeginAsync(cancellationToken);

                            Cells = new List <FCell>(_list393.Count);
                            for (int _i394 = 0; _i394 < _list393.Count; ++_i394)
                            {
                                FCell _elem395;
                                _elem395 = new FCell();
                                await _elem395.ReadAsync(iprot, cancellationToken);

                                Cells.Add(_elem395);
                            }
                            await iprot.ReadListEndAsync(cancellationToken);
                        }
                    }
                    else
                    {
                        await TProtocolUtil.SkipAsync(iprot, field.Type, cancellationToken);
                    }
                    break;

                case 3:
                    if (field.Type == TType.List)
                    {
                        {
                            TList _list396 = await iprot.ReadListBeginAsync(cancellationToken);

                            Serial_cells = new List <FCellSerial>(_list396.Count);
                            for (int _i397 = 0; _i397 < _list396.Count; ++_i397)
                            {
                                FCellSerial _elem398;
                                _elem398 = new FCellSerial();
                                await _elem398.ReadAsync(iprot, cancellationToken);

                                Serial_cells.Add(_elem398);
                            }
                            await iprot.ReadListEndAsync(cancellationToken);
                        }
                    }
                    else
                    {
                        await TProtocolUtil.SkipAsync(iprot, field.Type, cancellationToken);
                    }
                    break;

                default:
                    await TProtocolUtil.SkipAsync(iprot, field.Type, cancellationToken);

                    break;
                }

                await iprot.ReadFieldEndAsync(cancellationToken);
            }

            await iprot.ReadStructEndAsync(cancellationToken);
        }
        finally
        {
            iprot.DecrementRecursionDepth();
        }
    }
Beispiel #3
0
    public async global::System.Threading.Tasks.Task ReadAsync(TProtocol iprot, CancellationToken cancellationToken)
    {
        iprot.IncrementRecursionDepth();
        try
        {
            TField field;
            await iprot.ReadStructBeginAsync(cancellationToken);

            while (true)
            {
                field = await iprot.ReadFieldBeginAsync(cancellationToken);

                if (field.Type == TType.Stop)
                {
                    break;
                }

                switch (field.ID)
                {
                case 1:
                    if (field.Type == TType.Struct)
                    {
                        Cells = new Cells();
                        await Cells.ReadAsync(iprot, cancellationToken);
                    }
                    else
                    {
                        await TProtocolUtil.SkipAsync(iprot, field.Type, cancellationToken);
                    }
                    break;

                case 2:
                    if (field.Type == TType.Map)
                    {
                        {
                            TMap _map407 = await iprot.ReadMapBeginAsync(cancellationToken);

                            Ccells = new Dictionary <string, ColCells>(_map407.Count);
                            for (int _i408 = 0; _i408 < _map407.Count; ++_i408)
                            {
                                string   _key409;
                                ColCells _val410;
                                _key409 = await iprot.ReadStringAsync(cancellationToken);

                                _val410 = new ColCells();
                                await _val410.ReadAsync(iprot, cancellationToken);

                                Ccells[_key409] = _val410;
                            }
                            await iprot.ReadMapEndAsync(cancellationToken);
                        }
                    }
                    else
                    {
                        await TProtocolUtil.SkipAsync(iprot, field.Type, cancellationToken);
                    }
                    break;

                case 3:
                    if (field.Type == TType.List)
                    {
                        {
                            TList _list411 = await iprot.ReadListBeginAsync(cancellationToken);

                            Kcells = new List <kCells>(_list411.Count);
                            for (int _i412 = 0; _i412 < _list411.Count; ++_i412)
                            {
                                kCells _elem413;
                                _elem413 = new kCells();
                                await _elem413.ReadAsync(iprot, cancellationToken);

                                Kcells.Add(_elem413);
                            }
                            await iprot.ReadListEndAsync(cancellationToken);
                        }
                    }
                    else
                    {
                        await TProtocolUtil.SkipAsync(iprot, field.Type, cancellationToken);
                    }
                    break;

                case 4:
                    if (field.Type == TType.Struct)
                    {
                        Fcells = new FCells();
                        await Fcells.ReadAsync(iprot, cancellationToken);
                    }
                    else
                    {
                        await TProtocolUtil.SkipAsync(iprot, field.Type, cancellationToken);
                    }
                    break;

                default:
                    await TProtocolUtil.SkipAsync(iprot, field.Type, cancellationToken);

                    break;
                }

                await iprot.ReadFieldEndAsync(cancellationToken);
            }

            await iprot.ReadStructEndAsync(cancellationToken);
        }
        finally
        {
            iprot.DecrementRecursionDepth();
        }
    }