public void Read (TProtocol iprot)
 {
   iprot.IncrementRecursionDepth();
   try
   {
     TField field;
     iprot.ReadStructBegin();
     while (true)
     {
       field = iprot.ReadFieldBegin();
       if (field.Type == TType.Stop) { 
         break;
       }
       switch (field.ID)
       {
         case 1:
           if (field.Type == TType.Set) {
             {
               UpdateAttributes = new THashSet<SquareFeatureSetAttribute>();
               TSet _set501 = iprot.ReadSetBegin();
               for( int _i502 = 0; _i502 < _set501.Count; ++_i502)
               {
                 SquareFeatureSetAttribute _elem503;
                 _elem503 = (SquareFeatureSetAttribute)iprot.ReadI32();
                 UpdateAttributes.Add(_elem503);
               }
               iprot.ReadSetEnd();
             }
           } else { 
             TProtocolUtil.Skip(iprot, field.Type);
           }
           break;
         case 2:
           if (field.Type == TType.Struct) {
             SquareFeatureSet = new SquareFeatureSet();
             SquareFeatureSet.Read(iprot);
           } else { 
             TProtocolUtil.Skip(iprot, field.Type);
           }
           break;
         default: 
           TProtocolUtil.Skip(iprot, field.Type);
           break;
       }
       iprot.ReadFieldEnd();
     }
     iprot.ReadStructEnd();
   }
   finally
   {
     iprot.DecrementRecursionDepth();
   }
 }
Ejemplo n.º 2
0
        public HashSet <V> Read(TProtocol iprot)
        {
            TSet        tSet  = iprot.ReadSetBegin();
            HashSet <V> value = new HashSet <V>();

            for (int i = 0; i < tSet.Count; ++i)
            {
                V element = this.ValueMetadata.Read(iprot);
                value.Add(element);
            }
            iprot.ReadSetEnd();
            return(value);
        }
    public void Read(TProtocol iprot)
    {
        iprot.IncrementRecursionDepth();
        try
        {
            TField field;
            iprot.ReadStructBegin();
            while (true)
            {
                field = iprot.ReadFieldBegin();
                if (field.Type == TType.Stop)
                {
                    break;
                }
                switch (field.ID)
                {
                case 2:
                    if (field.Type == TType.Set)
                    {
                        {
                            Mids = new THashSet <string>();
                            TSet _set365 = iprot.ReadSetBegin();
                            for (int _i366 = 0; _i366 < _set365.Count; ++_i366)
                            {
                                string _elem367;
                                _elem367 = iprot.ReadString();
                                Mids.Add(_elem367);
                            }
                            iprot.ReadSetEnd();
                        }
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                default:
                    TProtocolUtil.Skip(iprot, field.Type);
                    break;
                }
                iprot.ReadFieldEnd();
            }
            iprot.ReadStructEnd();
        }
        finally
        {
            iprot.DecrementRecursionDepth();
        }
    }
Ejemplo n.º 4
0
        public void Read(TProtocol iprot)
        {
            iprot.IncrementRecursionDepth();
            try
            {
                TField field;
                iprot.ReadStructBegin();
                while (true)
                {
                    field = iprot.ReadFieldBegin();
                    if (field.Type == TType.Stop)
                    {
                        break;
                    }
                    switch (field.ID)
                    {
                    case 0:
                        if (field.Type == TType.Set)
                        {
                            {
                                Success = new THashSet <long>();
                                TSet _set37 = iprot.ReadSetBegin();
                                for (int _i38 = 0; _i38 < _set37.Count; ++_i38)
                                {
                                    long _elem39;
                                    _elem39 = iprot.ReadI64();
                                    Success.Add(_elem39);
                                }
                                iprot.ReadSetEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    default:
                        TProtocolUtil.Skip(iprot, field.Type);
                        break;
                    }
                    iprot.ReadFieldEnd();
                }
                iprot.ReadStructEnd();
            }
            finally
            {
                iprot.DecrementRecursionDepth();
            }
        }
Ejemplo n.º 5
0
        public void Read(TProtocol iprot)
        {
            bool   isset_value = false;
            TField field;

            iprot.ReadStructBegin();
            while (true)
            {
                field = iprot.ReadFieldBegin();
                if (field.Type == TType.Stop)
                {
                    break;
                }
                switch (field.ID)
                {
                case 1:
                    if (field.Type == TType.Set)
                    {
                        {
                            Value = new THashSet <int>();
                            TSet _set5 = iprot.ReadSetBegin();
                            for (int _i6 = 0; _i6 < _set5.Count; ++_i6)
                            {
                                int _elem7;
                                _elem7 = iprot.ReadI32();
                                Value.Add(_elem7);
                            }
                            iprot.ReadSetEnd();
                        }
                        isset_value = true;
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                default:
                    TProtocolUtil.Skip(iprot, field.Type);
                    break;
                }
                iprot.ReadFieldEnd();
            }
            iprot.ReadStructEnd();
            if (!isset_value)
            {
                throw new TProtocolException(TProtocolException.INVALID_DATA);
            }
        }
Ejemplo n.º 6
0
        public void Read(TProtocol iprot)
        {
            TField field;

            iprot.ReadStructBegin();
            while (true)
            {
                field = iprot.ReadFieldBegin();
                if (field.Type == TType.Stop)
                {
                    break;
                }
                switch (field.ID)
                {
                case 1:
                    if (field.Type == TType.Set)
                    {
                        {
                            this.values = new THashSet <Value>();
                            TSet _set9 = iprot.ReadSetBegin();
                            for (int _i10 = 0; _i10 < _set9.Count; ++_i10)
                            {
                                Value _elem11 = new Value();
                                _elem11 = new Value();
                                _elem11.Read(iprot);
                                this.values.Add(_elem11);
                            }
                            iprot.ReadSetEnd();
                        }
                        this.__isset.values = true;
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                default:
                    TProtocolUtil.Skip(iprot, field.Type);
                    break;
                }
                iprot.ReadFieldEnd();
            }
            iprot.ReadStructEnd();
        }
        public void Read(TProtocol iprot)
        {
            iprot.IncrementRecursionDepth();
            try
            {
                TField field;
                iprot.ReadStructBegin();
                while (true)
                {
                    field = iprot.ReadFieldBegin();
                    if (field.Type == TType.Stop)
                    {
                        break;
                    }
                    switch (field.ID)
                    {
                    case 1:
                        if (field.Type == TType.List)
                        {
                            {
                                Int_set_list = new List <THashSet <int> >();
                                TList _list103 = iprot.ReadListBegin();
                                for (int _i104 = 0; _i104 < _list103.Count; ++_i104)
                                {
                                    THashSet <int> _elem105;
                                    {
                                        _elem105 = new THashSet <int>();
                                        TSet _set106 = iprot.ReadSetBegin();
                                        for (int _i107 = 0; _i107 < _set106.Count; ++_i107)
                                        {
                                            int _elem108;
                                            _elem108 = iprot.ReadI32();
                                            _elem105.Add(_elem108);
                                        }
                                        iprot.ReadSetEnd();
                                    }
                                    Int_set_list.Add(_elem105);
                                }
                                iprot.ReadListEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 2:
                        if (field.Type == TType.Map)
                        {
                            {
                                Map_int_strset = new Dictionary <int, THashSet <string> >();
                                TMap _map109 = iprot.ReadMapBegin();
                                for (int _i110 = 0; _i110 < _map109.Count; ++_i110)
                                {
                                    int _key111;
                                    THashSet <string> _val112;
                                    _key111 = iprot.ReadI32();
                                    {
                                        _val112 = new THashSet <string>();
                                        TSet _set113 = iprot.ReadSetBegin();
                                        for (int _i114 = 0; _i114 < _set113.Count; ++_i114)
                                        {
                                            string _elem115;
                                            _elem115 = iprot.ReadString();
                                            _val112.Add(_elem115);
                                        }
                                        iprot.ReadSetEnd();
                                    }
                                    Map_int_strset[_key111] = _val112;
                                }
                                iprot.ReadMapEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 3:
                        if (field.Type == TType.List)
                        {
                            {
                                Map_int_strset_list = new List <Dictionary <int, THashSet <string> > >();
                                TList _list116 = iprot.ReadListBegin();
                                for (int _i117 = 0; _i117 < _list116.Count; ++_i117)
                                {
                                    Dictionary <int, THashSet <string> > _elem118;
                                    {
                                        _elem118 = new Dictionary <int, THashSet <string> >();
                                        TMap _map119 = iprot.ReadMapBegin();
                                        for (int _i120 = 0; _i120 < _map119.Count; ++_i120)
                                        {
                                            int _key121;
                                            THashSet <string> _val122;
                                            _key121 = iprot.ReadI32();
                                            {
                                                _val122 = new THashSet <string>();
                                                TSet _set123 = iprot.ReadSetBegin();
                                                for (int _i124 = 0; _i124 < _set123.Count; ++_i124)
                                                {
                                                    string _elem125;
                                                    _elem125 = iprot.ReadString();
                                                    _val122.Add(_elem125);
                                                }
                                                iprot.ReadSetEnd();
                                            }
                                            _elem118[_key121] = _val122;
                                        }
                                        iprot.ReadMapEnd();
                                    }
                                    Map_int_strset_list.Add(_elem118);
                                }
                                iprot.ReadListEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    default:
                        TProtocolUtil.Skip(iprot, field.Type);
                        break;
                    }
                    iprot.ReadFieldEnd();
                }
                iprot.ReadStructEnd();
            }
            finally
            {
                iprot.DecrementRecursionDepth();
            }
        }
Ejemplo n.º 8
0
        public void Read(TProtocol iprot)
        {
            iprot.IncrementRecursionDepth();
            try
            {
                TField field;
                iprot.ReadStructBegin();
                while (true)
                {
                    field = iprot.ReadFieldBegin();
                    if (field.Type == TType.Stop)
                    {
                        break;
                    }
                    switch (field.ID)
                    {
                    case 1:
                        if (field.Type == TType.Struct)
                        {
                            B1 = new Bools();
                            B1.Read(iprot);
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 10:
                        if (field.Type == TType.Struct)
                        {
                            B10 = new Bools();
                            B10.Read(iprot);
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 100:
                        if (field.Type == TType.Struct)
                        {
                            B100 = new Bools();
                            B100.Read(iprot);
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 500:
                        if (field.Type == TType.Bool)
                        {
                            Check_true = iprot.ReadBool();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 1000:
                        if (field.Type == TType.Struct)
                        {
                            B1000 = new Bools();
                            B1000.Read(iprot);
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 1500:
                        if (field.Type == TType.Bool)
                        {
                            Check_false = iprot.ReadBool();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 2000:
                        if (field.Type == TType.Struct)
                        {
                            Vertwo2000 = new VersioningTestV2();
                            Vertwo2000.Read(iprot);
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 2500:
                        if (field.Type == TType.Set)
                        {
                            {
                                A_set2500 = new THashSet <string>();
                                TSet _set75 = iprot.ReadSetBegin();
                                for (int _i76 = 0; _i76 < _set75.Count; ++_i76)
                                {
                                    string _elem77;
                                    _elem77 = iprot.ReadString();
                                    A_set2500.Add(_elem77);
                                }
                                iprot.ReadSetEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 3000:
                        if (field.Type == TType.Struct)
                        {
                            Vertwo3000 = new VersioningTestV2();
                            Vertwo3000.Read(iprot);
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 4000:
                        if (field.Type == TType.List)
                        {
                            {
                                Big_numbers = new List <int>();
                                TList _list78 = iprot.ReadListBegin();
                                for (int _i79 = 0; _i79 < _list78.Count; ++_i79)
                                {
                                    int _elem80;
                                    _elem80 = iprot.ReadI32();
                                    Big_numbers.Add(_elem80);
                                }
                                iprot.ReadListEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    default:
                        TProtocolUtil.Skip(iprot, field.Type);
                        break;
                    }
                    iprot.ReadFieldEnd();
                }
                iprot.ReadStructEnd();
            }
            finally
            {
                iprot.DecrementRecursionDepth();
            }
        }
    public void Read(TProtocol iprot)
    {
        iprot.IncrementRecursionDepth();
        try
        {
            TField field;
            iprot.ReadStructBegin();
            while (true)
            {
                field = iprot.ReadFieldBegin();
                if (field.Type == TType.Stop)
                {
                    break;
                }
                switch (field.ID)
                {
                case 2:
                    if (field.Type == TType.Set)
                    {
                        {
                            UpdateAttributes = new THashSet <SquareAuthorityAttribute>();
                            TSet _set483 = iprot.ReadSetBegin();
                            for (int _i484 = 0; _i484 < _set483.Count; ++_i484)
                            {
                                SquareAuthorityAttribute _elem485;
                                _elem485 = (SquareAuthorityAttribute)iprot.ReadI32();
                                UpdateAttributes.Add(_elem485);
                            }
                            iprot.ReadSetEnd();
                        }
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 3:
                    if (field.Type == TType.Struct)
                    {
                        Authority = new SquareAuthority();
                        Authority.Read(iprot);
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                default:
                    TProtocolUtil.Skip(iprot, field.Type);
                    break;
                }
                iprot.ReadFieldEnd();
            }
            iprot.ReadStructEnd();
        }
        finally
        {
            iprot.DecrementRecursionDepth();
        }
    }
Ejemplo n.º 10
0
    public void Read(TProtocol iprot)
    {
        iprot.IncrementRecursionDepth();
        try
        {
            TField field;
            iprot.ReadStructBegin();
            while (true)
            {
                field = iprot.ReadFieldBegin();
                if (field.Type == TType.Stop)
                {
                    break;
                }
                switch (field.ID)
                {
                case 1:
                    if (field.Type == TType.I32)
                    {
                        MembershipState = (SquareMembershipState)iprot.ReadI32();
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 2:
                    if (field.Type == TType.Set)
                    {
                        {
                            MemberRoles = new THashSet <SquareMemberRole>();
                            TSet _set417 = iprot.ReadSetBegin();
                            for (int _i418 = 0; _i418 < _set417.Count; ++_i418)
                            {
                                SquareMemberRole _elem419;
                                _elem419 = (SquareMemberRole)iprot.ReadI32();
                                MemberRoles.Add(_elem419);
                            }
                            iprot.ReadSetEnd();
                        }
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 3:
                    if (field.Type == TType.String)
                    {
                        DisplayName = iprot.ReadString();
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 4:
                    if (field.Type == TType.I32)
                    {
                        AbleToReceiveMessage = (BooleanState)iprot.ReadI32();
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 5:
                    if (field.Type == TType.I32)
                    {
                        AbleToReceiveFriendRequest = (BooleanState)iprot.ReadI32();
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 6:
                    if (field.Type == TType.String)
                    {
                        ChatMidToExcludeMembers = iprot.ReadString();
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 7:
                    if (field.Type == TType.Bool)
                    {
                        IncludingMe = iprot.ReadBool();
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                default:
                    TProtocolUtil.Skip(iprot, field.Type);
                    break;
                }
                iprot.ReadFieldEnd();
            }
            iprot.ReadStructEnd();
        }
        finally
        {
            iprot.DecrementRecursionDepth();
        }
    }
Ejemplo n.º 11
0
    public void Read(TProtocol iprot)
    {
        bool   isset_node = false;
        bool   isset_port = false;
        TField field;

        iprot.ReadStructBegin();
        while (true)
        {
            field = iprot.ReadFieldBegin();
            if (field.Type == TType.Stop)
            {
                break;
            }
            switch (field.ID)
            {
            case 1:
                if (field.Type == TType.String)
                {
                    Node       = iprot.ReadString();
                    isset_node = true;
                }
                else
                {
                    TProtocolUtil.Skip(iprot, field.Type);
                }
                break;

            case 2:
                if (field.Type == TType.Set)
                {
                    {
                        Port = new THashSet <long>();
                        TSet _set181 = iprot.ReadSetBegin();
                        for (int _i182 = 0; _i182 < _set181.Count; ++_i182)
                        {
                            long _elem183;
                            _elem183 = iprot.ReadI64();
                            Port.Add(_elem183);
                        }
                        iprot.ReadSetEnd();
                    }
                    isset_port = true;
                }
                else
                {
                    TProtocolUtil.Skip(iprot, field.Type);
                }
                break;

            default:
                TProtocolUtil.Skip(iprot, field.Type);
                break;
            }
            iprot.ReadFieldEnd();
        }
        iprot.ReadStructEnd();
        if (!isset_node)
        {
            throw new TProtocolException(TProtocolException.INVALID_DATA);
        }
        if (!isset_port)
        {
            throw new TProtocolException(TProtocolException.INVALID_DATA);
        }
    }
Ejemplo n.º 12
0
        public void Read(TProtocol iprot)
        {
            iprot.IncrementRecursionDepth();
            try
            {
                TField field;
                iprot.ReadStructBegin();
                while (true)
                {
                    field = iprot.ReadFieldBegin();
                    if (field.Type == TType.Stop)
                    {
                        break;
                    }
                    switch (field.ID)
                    {
                    case 1:
                        if (field.Type == TType.String)
                        {
                            SessionId = iprot.ReadString();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 2:
                        if (field.Type == TType.String)
                        {
                            AppId = iprot.ReadString();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 3:
                        if (field.Type == TType.Set)
                        {
                            {
                                Ids = new THashSet <SGEntity>();
                                TSet _set226 = iprot.ReadSetBegin();
                                for (int _i227 = 0; _i227 < _set226.Count; ++_i227)
                                {
                                    SGEntity _elem228;
                                    _elem228 = new SGEntity();
                                    _elem228.Read(iprot);
                                    Ids.Add(_elem228);
                                }
                                iprot.ReadSetEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 4:
                        if (field.Type == TType.String)
                        {
                            Reaction = iprot.ReadString();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    default:
                        TProtocolUtil.Skip(iprot, field.Type);
                        break;
                    }
                    iprot.ReadFieldEnd();
                }
                iprot.ReadStructEnd();
            }
            finally
            {
                iprot.DecrementRecursionDepth();
            }
        }
Ejemplo n.º 13
0
        public void Read(TProtocol iprot)
        {
            iprot.IncrementRecursionDepth();
            try
            {
                TField field;
                iprot.ReadStructBegin();
                while (true)
                {
                    field = iprot.ReadFieldBegin();
                    if (field.Type == TType.Stop)
                    {
                        break;
                    }
                    switch (field.ID)
                    {
                    case 1:
                        if (field.Type == TType.I32)
                        {
                            Begin_in_both = iprot.ReadI32();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 2:
                        if (field.Type == TType.I32)
                        {
                            Newint = iprot.ReadI32();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 3:
                        if (field.Type == TType.Byte)
                        {
                            Newbyte = iprot.ReadByte();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 4:
                        if (field.Type == TType.I16)
                        {
                            Newshort = iprot.ReadI16();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 5:
                        if (field.Type == TType.I64)
                        {
                            Newlong = iprot.ReadI64();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 6:
                        if (field.Type == TType.Double)
                        {
                            Newdouble = iprot.ReadDouble();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 7:
                        if (field.Type == TType.Struct)
                        {
                            Newstruct = new Bonk();
                            Newstruct.Read(iprot);
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 8:
                        if (field.Type == TType.List)
                        {
                            {
                                Newlist = new List <int>();
                                TList _list44 = iprot.ReadListBegin();
                                for (int _i45 = 0; _i45 < _list44.Count; ++_i45)
                                {
                                    int _elem46;
                                    _elem46 = iprot.ReadI32();
                                    Newlist.Add(_elem46);
                                }
                                iprot.ReadListEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 9:
                        if (field.Type == TType.Set)
                        {
                            {
                                Newset = new THashSet <int>();
                                TSet _set47 = iprot.ReadSetBegin();
                                for (int _i48 = 0; _i48 < _set47.Count; ++_i48)
                                {
                                    int _elem49;
                                    _elem49 = iprot.ReadI32();
                                    Newset.Add(_elem49);
                                }
                                iprot.ReadSetEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 10:
                        if (field.Type == TType.Map)
                        {
                            {
                                Newmap = new Dictionary <int, int>();
                                TMap _map50 = iprot.ReadMapBegin();
                                for (int _i51 = 0; _i51 < _map50.Count; ++_i51)
                                {
                                    int _key52;
                                    int _val53;
                                    _key52         = iprot.ReadI32();
                                    _val53         = iprot.ReadI32();
                                    Newmap[_key52] = _val53;
                                }
                                iprot.ReadMapEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 11:
                        if (field.Type == TType.String)
                        {
                            Newstring = iprot.ReadString();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 12:
                        if (field.Type == TType.I32)
                        {
                            End_in_both = iprot.ReadI32();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    default:
                        TProtocolUtil.Skip(iprot, field.Type);
                        break;
                    }
                    iprot.ReadFieldEnd();
                }
                iprot.ReadStructEnd();
            }
            finally
            {
                iprot.DecrementRecursionDepth();
            }
        }
Ejemplo n.º 14
0
        public void Read(TProtocol iprot)
        {
            bool   isset_value1  = false;
            bool   isset_value2  = false;
            bool   isset_value3  = false;
            bool   isset_value4  = false;
            bool   isset_value5  = false;
            bool   isset_value6  = false;
            bool   isset_value7  = false;
            bool   isset_value8  = false;
            bool   isset_value9  = false;
            bool   isset_value10 = false;
            bool   isset_value11 = false;
            bool   isset_value12 = false;
            TField field;

            iprot.ReadStructBegin();
            while (true)
            {
                field = iprot.ReadFieldBegin();
                if (field.Type == TType.Stop)
                {
                    break;
                }
                switch (field.ID)
                {
                case 1:
                    if (field.Type == TType.Bool)
                    {
                        Value1       = iprot.ReadBool();
                        isset_value1 = true;
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 2:
                    if (field.Type == TType.Byte)
                    {
                        Value2       = iprot.ReadByte();
                        isset_value2 = true;
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 3:
                    if (field.Type == TType.Double)
                    {
                        Value3       = iprot.ReadDouble();
                        isset_value3 = true;
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 4:
                    if (field.Type == TType.I16)
                    {
                        Value4       = iprot.ReadI16();
                        isset_value4 = true;
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 5:
                    if (field.Type == TType.I32)
                    {
                        Value5       = iprot.ReadI32();
                        isset_value5 = true;
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 6:
                    if (field.Type == TType.I64)
                    {
                        Value6       = iprot.ReadI64();
                        isset_value6 = true;
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 7:
                    if (field.Type == TType.String)
                    {
                        Value7       = iprot.ReadBinary();
                        isset_value7 = true;
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 8:
                    if (field.Type == TType.String)
                    {
                        Value8       = iprot.ReadString();
                        isset_value8 = true;
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 9:
                    if (field.Type == TType.Struct)
                    {
                        Value9 = new EmptyStruct();
                        Value9.Read(iprot);
                        isset_value9 = true;
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 10:
                    if (field.Type == TType.Map)
                    {
                        {
                            Value10 = new Dictionary <int, int>();
                            TMap _map25 = iprot.ReadMapBegin();
                            for (int _i26 = 0; _i26 < _map25.Count; ++_i26)
                            {
                                int _key27;
                                int _val28;
                                _key27          = iprot.ReadI32();
                                _val28          = iprot.ReadI32();
                                Value10[_key27] = _val28;
                            }
                            iprot.ReadMapEnd();
                        }
                        isset_value10 = true;
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 11:
                    if (field.Type == TType.Set)
                    {
                        {
                            Value11 = new THashSet <int>();
                            TSet _set29 = iprot.ReadSetBegin();
                            for (int _i30 = 0; _i30 < _set29.Count; ++_i30)
                            {
                                int _elem31;
                                _elem31 = iprot.ReadI32();
                                Value11.Add(_elem31);
                            }
                            iprot.ReadSetEnd();
                        }
                        isset_value11 = true;
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 12:
                    if (field.Type == TType.List)
                    {
                        {
                            Value12 = new List <int>();
                            TList _list32 = iprot.ReadListBegin();
                            for (int _i33 = 0; _i33 < _list32.Count; ++_i33)
                            {
                                int _elem34;
                                _elem34 = iprot.ReadI32();
                                Value12.Add(_elem34);
                            }
                            iprot.ReadListEnd();
                        }
                        isset_value12 = true;
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                default:
                    TProtocolUtil.Skip(iprot, field.Type);
                    break;
                }
                iprot.ReadFieldEnd();
            }
            iprot.ReadStructEnd();
            if (!isset_value1)
            {
                throw new TProtocolException(TProtocolException.INVALID_DATA);
            }
            if (!isset_value2)
            {
                throw new TProtocolException(TProtocolException.INVALID_DATA);
            }
            if (!isset_value3)
            {
                throw new TProtocolException(TProtocolException.INVALID_DATA);
            }
            if (!isset_value4)
            {
                throw new TProtocolException(TProtocolException.INVALID_DATA);
            }
            if (!isset_value5)
            {
                throw new TProtocolException(TProtocolException.INVALID_DATA);
            }
            if (!isset_value6)
            {
                throw new TProtocolException(TProtocolException.INVALID_DATA);
            }
            if (!isset_value7)
            {
                throw new TProtocolException(TProtocolException.INVALID_DATA);
            }
            if (!isset_value8)
            {
                throw new TProtocolException(TProtocolException.INVALID_DATA);
            }
            if (!isset_value9)
            {
                throw new TProtocolException(TProtocolException.INVALID_DATA);
            }
            if (!isset_value10)
            {
                throw new TProtocolException(TProtocolException.INVALID_DATA);
            }
            if (!isset_value11)
            {
                throw new TProtocolException(TProtocolException.INVALID_DATA);
            }
            if (!isset_value12)
            {
                throw new TProtocolException(TProtocolException.INVALID_DATA);
            }
        }
Ejemplo n.º 15
0
        public void Read(TProtocol iprot)
        {
            TField field;

            iprot.ReadStructBegin();
            while (true)
            {
                field = iprot.ReadFieldBegin();
                if (field.Type == TType.Stop)
                {
                    break;
                }
                switch (field.ID)
                {
                case 1:
                    if (field.Type == TType.Set)
                    {
                        {
                            KeysOnly = new THashSet <string>();
                            TSet _set8 = iprot.ReadSetBegin();
                            for (int _i9 = 0; _i9 < _set8.Count; ++_i9)
                            {
                                string _elem10 = null;
                                _elem10 = iprot.ReadString();
                                KeysOnly.Add(_elem10);
                            }
                            iprot.ReadSetEnd();
                        }
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 2:
                    if (field.Type == TType.Map)
                    {
                        {
                            FullMap = new Dictionary <string, string>();
                            TMap _map11 = iprot.ReadMapBegin();
                            for (int _i12 = 0; _i12 < _map11.Count; ++_i12)
                            {
                                string _key13;
                                string _val14;
                                _key13          = iprot.ReadString();
                                _val14          = iprot.ReadString();
                                FullMap[_key13] = _val14;
                            }
                            iprot.ReadMapEnd();
                        }
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                default:
                    TProtocolUtil.Skip(iprot, field.Type);
                    break;
                }
                iprot.ReadFieldEnd();
            }
            iprot.ReadStructEnd();
        }
Ejemplo n.º 16
0
        public void Read(TProtocol iprot)
        {
            iprot.IncrementRecursionDepth();
            try
            {
                bool   isset_list_field = false;
                TField field;
                iprot.ReadStructBegin();
                while (true)
                {
                    field = iprot.ReadFieldBegin();
                    if (field.Type == TType.Stop)
                    {
                        break;
                    }
                    switch (field.ID)
                    {
                    case 1:
                        if (field.Type == TType.String)
                        {
                            String_field = iprot.ReadString();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 2:
                        if (field.Type == TType.Set)
                        {
                            {
                                Set_field = new THashSet <Insanity>();
                                TSet _set9 = iprot.ReadSetBegin();
                                for (int _i10 = 0; _i10 < _set9.Count; ++_i10)
                                {
                                    Insanity _elem11;
                                    _elem11 = new Insanity();
                                    _elem11.Read(iprot);
                                    Set_field.Add(_elem11);
                                }
                                iprot.ReadSetEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 3:
                        if (field.Type == TType.List)
                        {
                            {
                                List_field = new List <Dictionary <THashSet <int>, Dictionary <int, THashSet <List <Dictionary <Insanity, string> > > > > >();
                                TList _list12 = iprot.ReadListBegin();
                                for (int _i13 = 0; _i13 < _list12.Count; ++_i13)
                                {
                                    Dictionary <THashSet <int>, Dictionary <int, THashSet <List <Dictionary <Insanity, string> > > > > _elem14;
                                    {
                                        _elem14 = new Dictionary <THashSet <int>, Dictionary <int, THashSet <List <Dictionary <Insanity, string> > > > >();
                                        TMap _map15 = iprot.ReadMapBegin();
                                        for (int _i16 = 0; _i16 < _map15.Count; ++_i16)
                                        {
                                            THashSet <int> _key17;
                                            Dictionary <int, THashSet <List <Dictionary <Insanity, string> > > > _val18;
                                            {
                                                _key17 = new THashSet <int>();
                                                TSet _set19 = iprot.ReadSetBegin();
                                                for (int _i20 = 0; _i20 < _set19.Count; ++_i20)
                                                {
                                                    int _elem21;
                                                    _elem21 = iprot.ReadI32();
                                                    _key17.Add(_elem21);
                                                }
                                                iprot.ReadSetEnd();
                                            }
                                            {
                                                _val18 = new Dictionary <int, THashSet <List <Dictionary <Insanity, string> > > >();
                                                TMap _map22 = iprot.ReadMapBegin();
                                                for (int _i23 = 0; _i23 < _map22.Count; ++_i23)
                                                {
                                                    int _key24;
                                                    THashSet <List <Dictionary <Insanity, string> > > _val25;
                                                    _key24 = iprot.ReadI32();
                                                    {
                                                        _val25 = new THashSet <List <Dictionary <Insanity, string> > >();
                                                        TSet _set26 = iprot.ReadSetBegin();
                                                        for (int _i27 = 0; _i27 < _set26.Count; ++_i27)
                                                        {
                                                            List <Dictionary <Insanity, string> > _elem28;
                                                            {
                                                                _elem28 = new List <Dictionary <Insanity, string> >();
                                                                TList _list29 = iprot.ReadListBegin();
                                                                for (int _i30 = 0; _i30 < _list29.Count; ++_i30)
                                                                {
                                                                    Dictionary <Insanity, string> _elem31;
                                                                    {
                                                                        _elem31 = new Dictionary <Insanity, string>();
                                                                        TMap _map32 = iprot.ReadMapBegin();
                                                                        for (int _i33 = 0; _i33 < _map32.Count; ++_i33)
                                                                        {
                                                                            Insanity _key34;
                                                                            string   _val35;
                                                                            _key34 = new Insanity();
                                                                            _key34.Read(iprot);
                                                                            _val35          = iprot.ReadString();
                                                                            _elem31[_key34] = _val35;
                                                                        }
                                                                        iprot.ReadMapEnd();
                                                                    }
                                                                    _elem28.Add(_elem31);
                                                                }
                                                                iprot.ReadListEnd();
                                                            }
                                                            _val25.Add(_elem28);
                                                        }
                                                        iprot.ReadSetEnd();
                                                    }
                                                    _val18[_key24] = _val25;
                                                }
                                                iprot.ReadMapEnd();
                                            }
                                            _elem14[_key17] = _val18;
                                        }
                                        iprot.ReadMapEnd();
                                    }
                                    List_field.Add(_elem14);
                                }
                                iprot.ReadListEnd();
                            }
                            isset_list_field = true;
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 4:
                        if (field.Type == TType.String)
                        {
                            Binary_field = iprot.ReadBinary();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    default:
                        TProtocolUtil.Skip(iprot, field.Type);
                        break;
                    }
                    iprot.ReadFieldEnd();
                }
                iprot.ReadStructEnd();
                if (!isset_list_field)
                {
                    throw new TProtocolException(TProtocolException.INVALID_DATA);
                }
            }
            finally
            {
                iprot.DecrementRecursionDepth();
            }
        }
Ejemplo n.º 17
0
    public void Read(TProtocol iprot)
    {
        iprot.IncrementRecursionDepth();
        try
        {
            TField field;
            iprot.ReadStructBegin();
            while (true)
            {
                field = iprot.ReadFieldBegin();
                if (field.Type == TType.Stop)
                {
                    break;
                }
                switch (field.ID)
                {
                case 2:
                    if (field.Type == TType.Set)
                    {
                        {
                            UpdatedAttrs = new THashSet <SquareMemberAttribute>();
                            TSet _set521 = iprot.ReadSetBegin();
                            for (int _i522 = 0; _i522 < _set521.Count; ++_i522)
                            {
                                SquareMemberAttribute _elem523;
                                _elem523 = (SquareMemberAttribute)iprot.ReadI32();
                                UpdatedAttrs.Add(_elem523);
                            }
                            iprot.ReadSetEnd();
                        }
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 3:
                    if (field.Type == TType.List)
                    {
                        {
                            Members = new List <SquareMember>();
                            TList _list524 = iprot.ReadListBegin();
                            for (int _i525 = 0; _i525 < _list524.Count; ++_i525)
                            {
                                SquareMember _elem526;
                                _elem526 = new SquareMember();
                                _elem526.Read(iprot);
                                Members.Add(_elem526);
                            }
                            iprot.ReadListEnd();
                        }
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                default:
                    TProtocolUtil.Skip(iprot, field.Type);
                    break;
                }
                iprot.ReadFieldEnd();
            }
            iprot.ReadStructEnd();
        }
        finally
        {
            iprot.DecrementRecursionDepth();
        }
    }
    public void Read(TProtocol iprot)
    {
        iprot.IncrementRecursionDepth();
        try
        {
            TField field;
            iprot.ReadStructBegin();
            while (true)
            {
                field = iprot.ReadFieldBegin();
                if (field.Type == TType.Stop)
                {
                    break;
                }
                switch (field.ID)
                {
                case 1:
                    if (field.Type == TType.String)
                    {
                        SquareMid = iprot.ReadString();
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 2:
                    if (field.Type == TType.String)
                    {
                        TargetSquareMemberMid = iprot.ReadString();
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 3:
                    if (field.Type == TType.Set)
                    {
                        {
                            UpdatedAttrs = new THashSet <SquareMemberRelationAttribute>();
                            TSet _set583 = iprot.ReadSetBegin();
                            for (int _i584 = 0; _i584 < _set583.Count; ++_i584)
                            {
                                SquareMemberRelationAttribute _elem585;
                                _elem585 = (SquareMemberRelationAttribute)iprot.ReadI32();
                                UpdatedAttrs.Add(_elem585);
                            }
                            iprot.ReadSetEnd();
                        }
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 4:
                    if (field.Type == TType.Struct)
                    {
                        Relation = new SquareMemberRelation();
                        Relation.Read(iprot);
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                default:
                    TProtocolUtil.Skip(iprot, field.Type);
                    break;
                }
                iprot.ReadFieldEnd();
            }
            iprot.ReadStructEnd();
        }
        finally
        {
            iprot.DecrementRecursionDepth();
        }
    }
Ejemplo n.º 19
0
    public void Read(TProtocol iprot)
    {
        iprot.IncrementRecursionDepth();
        try
        {
            TField field;
            iprot.ReadStructBegin();
            while (true)
            {
                field = iprot.ReadFieldBegin();
                if (field.Type == TType.Stop)
                {
                    break;
                }
                switch (field.ID)
                {
                case 1:
                    if (field.Type == TType.String)
                    {
                        Mid = iprot.ReadString();
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 2:
                    if (field.Type == TType.I64)
                    {
                        MemberCount = iprot.ReadI64();
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 3:
                    if (field.Type == TType.Bool)
                    {
                        OnAir = iprot.ReadBool();
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 4:
                    if (field.Type == TType.Bool)
                    {
                        BusinessAccount = iprot.ReadBool();
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 5:
                    if (field.Type == TType.Bool)
                    {
                        Addable = iprot.ReadBool();
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 6:
                    if (field.Type == TType.Set)
                    {
                        {
                            AcceptableContentTypes = new THashSet <ContentType>();
                            TSet _set131 = iprot.ReadSetBegin();
                            for (int _i132 = 0; _i132 < _set131.Count; ++_i132)
                            {
                                ContentType _elem133;
                                _elem133 = (ContentType)iprot.ReadI32();
                                AcceptableContentTypes.Add(_elem133);
                            }
                            iprot.ReadSetEnd();
                        }
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 7:
                    if (field.Type == TType.Bool)
                    {
                        CapableMyhome = iprot.ReadBool();
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                default:
                    TProtocolUtil.Skip(iprot, field.Type);
                    break;
                }
                iprot.ReadFieldEnd();
            }
            iprot.ReadStructEnd();
        }
        finally
        {
            iprot.DecrementRecursionDepth();
        }
    }
    public void Read(TProtocol iprot)
    {
        iprot.IncrementRecursionDepth();
        try
        {
            TField field;
            iprot.ReadStructBegin();
            while (true)
            {
                field = iprot.ReadFieldBegin();
                if (field.Type == TType.Stop)
                {
                    break;
                }
                switch (field.ID)
                {
                case 2:
                    if (field.Type == TType.Set)
                    {
                        {
                            UpdatedAttrs = new THashSet <SquareMemberAttribute>();
                            TSet _set505 = iprot.ReadSetBegin();
                            for (int _i506 = 0; _i506 < _set505.Count; ++_i506)
                            {
                                SquareMemberAttribute _elem507;
                                _elem507 = (SquareMemberAttribute)iprot.ReadI32();
                                UpdatedAttrs.Add(_elem507);
                            }
                            iprot.ReadSetEnd();
                        }
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 3:
                    if (field.Type == TType.Set)
                    {
                        {
                            UpdatedPreferenceAttrs = new THashSet <SquarePreferenceAttribute>();
                            TSet _set508 = iprot.ReadSetBegin();
                            for (int _i509 = 0; _i509 < _set508.Count; ++_i509)
                            {
                                SquarePreferenceAttribute _elem510;
                                _elem510 = (SquarePreferenceAttribute)iprot.ReadI32();
                                UpdatedPreferenceAttrs.Add(_elem510);
                            }
                            iprot.ReadSetEnd();
                        }
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 4:
                    if (field.Type == TType.Struct)
                    {
                        SquareMember = new SquareMember();
                        SquareMember.Read(iprot);
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                default:
                    TProtocolUtil.Skip(iprot, field.Type);
                    break;
                }
                iprot.ReadFieldEnd();
            }
            iprot.ReadStructEnd();
        }
        finally
        {
            iprot.DecrementRecursionDepth();
        }
    }
Ejemplo n.º 21
0
        public void Read(TProtocol iprot)
        {
            iprot.IncrementRecursionDepth();
            try
            {
                TField field;
                iprot.ReadStructBegin();
                while (true)
                {
                    field = iprot.ReadFieldBegin();
                    if (field.Type == TType.Stop)
                    {
                        break;
                    }
                    switch (field.ID)
                    {
                    case 1:
                        if (field.Type == TType.String)
                        {
                            SessionId = iprot.ReadString();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 2:
                        if (field.Type == TType.String)
                        {
                            AppId = iprot.ReadString();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 3:
                        if (field.Type == TType.Set)
                        {
                            {
                                Ids = new THashSet <string>();
                                TSet _set174 = iprot.ReadSetBegin();
                                for (int _i175 = 0; _i175 < _set174.Count; ++_i175)
                                {
                                    string _elem176;
                                    _elem176 = iprot.ReadString();
                                    Ids.Add(_elem176);
                                }
                                iprot.ReadSetEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    default:
                        TProtocolUtil.Skip(iprot, field.Type);
                        break;
                    }
                    iprot.ReadFieldEnd();
                }
                iprot.ReadStructEnd();
            }
            finally
            {
                iprot.DecrementRecursionDepth();
            }
        }
Ejemplo n.º 22
0
		public static void Skip(TProtocol prot, TType type)
		{
			switch (type)
			{
				case TType.Bool:
					prot.ReadBool();
					break;
				case TType.Byte:
					prot.ReadByte();
					break;
				case TType.I16:
					prot.ReadI16();
					break;
				case TType.I32:
					prot.ReadI32();
					break;
				case TType.I64:
					prot.ReadI64();
					break;
				case TType.Double:
					prot.ReadDouble();
					break;
				case TType.String:
					// Don't try to decode the string, just skip it.
					prot.ReadBinary();
					break;
				case TType.Struct:
					prot.ReadStructBegin();
					while (true)
					{
						TField field = prot.ReadFieldBegin();
						if (field.Type == TType.Stop)
						{
							break;
						}
						Skip(prot, field.Type);
						prot.ReadFieldEnd();
					}
					prot.ReadStructEnd();
					break;
				case TType.Map:
					TMap map = prot.ReadMapBegin();
					for (int i = 0; i < map.Count; i++)
					{
						Skip(prot, map.KeyType);
						Skip(prot, map.ValueType);
					}
					prot.ReadMapEnd();
					break;
				case TType.Set:
					TSet set = prot.ReadSetBegin();
					for (int i = 0; i < set.Count; i++)
					{
						Skip(prot, set.ElementType);
					}
					prot.ReadSetEnd();
					break;
				case TType.List:
					TList list = prot.ReadListBegin();
					for (int i = 0; i < list.Count; i++)
					{
						Skip(prot, list.ElementType);
					}
					prot.ReadListEnd();
					break;
			}
		}
Ejemplo n.º 23
0
    public void Read(TProtocol iprot)
    {
        iprot.IncrementRecursionDepth();
        try
        {
            TField field;
            iprot.ReadStructBegin();
            while (true)
            {
                field = iprot.ReadFieldBegin();
                if (field.Type == TType.Stop)
                {
                    break;
                }
                switch (field.ID)
                {
                case 1:
                    if (field.Type == TType.Set)
                    {
                        {
                            UpdatedAttrs = new THashSet <SquareAttribute>();
                            TSet _set386 = iprot.ReadSetBegin();
                            for (int _i387 = 0; _i387 < _set386.Count; ++_i387)
                            {
                                SquareAttribute _elem388;
                                _elem388 = (SquareAttribute)iprot.ReadI32();
                                UpdatedAttrs.Add(_elem388);
                            }
                            iprot.ReadSetEnd();
                        }
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 2:
                    if (field.Type == TType.Struct)
                    {
                        Square = new Square();
                        Square.Read(iprot);
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                default:
                    TProtocolUtil.Skip(iprot, field.Type);
                    break;
                }
                iprot.ReadFieldEnd();
            }
            iprot.ReadStructEnd();
        }
        finally
        {
            iprot.DecrementRecursionDepth();
        }
    }
Ejemplo n.º 24
0
        public static void Skip(TProtocol prot, TType type)
        {
            prot.IncrementRecursionDepth();
            try
            {
                switch (type)
                {
                case TType.Bool:
                    prot.ReadBool();
                    break;

                case TType.Byte:
                    prot.ReadByte();
                    break;

                case TType.I16:
                    prot.ReadI16();
                    break;

                case TType.I32:
                    prot.ReadI32();
                    break;

                case TType.I64:
                    prot.ReadI64();
                    break;

                case TType.Double:
                    prot.ReadDouble();
                    break;

                case TType.String:
                    // Don't try to decode the string, just skip it.
                    prot.ReadBinary();
                    break;

                case TType.Struct:
                    prot.ReadStructBegin();
                    while (true)
                    {
                        var field = prot.ReadFieldBegin();
                        if (field.Type == TType.Stop)
                        {
                            break;
                        }
                        Skip(prot, field.Type);
                        prot.ReadFieldEnd();
                    }
                    prot.ReadStructEnd();
                    break;

                case TType.Map:
                    var map = prot.ReadMapBegin();
                    for (var i = 0; i < map.Count; i++)
                    {
                        Skip(prot, map.KeyType);
                        Skip(prot, map.ValueType);
                    }
                    prot.ReadMapEnd();
                    break;

                case TType.Set:
                    var set = prot.ReadSetBegin();
                    for (var i = 0; i < set.Count; i++)
                    {
                        Skip(prot, set.ElementType);
                    }
                    prot.ReadSetEnd();
                    break;

                case TType.List:
                    var list = prot.ReadListBegin();
                    for (var i = 0; i < list.Count; i++)
                    {
                        Skip(prot, list.ElementType);
                    }
                    prot.ReadListEnd();
                    break;

                default:
                    throw new TProtocolException(TProtocolException.INVALID_DATA, "Unknown data type " + type.ToString("d"));
                }
            }
            finally
            {
                prot.DecrementRecursionDepth();
            }
        }
Ejemplo n.º 25
0
        public void Read(TProtocol iprot)
        {
            iprot.IncrementRecursionDepth();
            try
            {
                TField field;
                iprot.ReadStructBegin();
                while (true)
                {
                    field = iprot.ReadFieldBegin();
                    if (field.Type == TType.Stop)
                    {
                        break;
                    }
                    switch (field.ID)
                    {
                    case 1:
                        if (field.Type == TType.Bool)
                        {
                            IncludeNotes = iprot.ReadBool();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 2:
                        if (field.Type == TType.Bool)
                        {
                            IncludeNoteResources = iprot.ReadBool();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 3:
                        if (field.Type == TType.Bool)
                        {
                            IncludeNoteAttributes = iprot.ReadBool();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 4:
                        if (field.Type == TType.Bool)
                        {
                            IncludeNotebooks = iprot.ReadBool();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 5:
                        if (field.Type == TType.Bool)
                        {
                            IncludeTags = iprot.ReadBool();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 6:
                        if (field.Type == TType.Bool)
                        {
                            IncludeSearches = iprot.ReadBool();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 7:
                        if (field.Type == TType.Bool)
                        {
                            IncludeResources = iprot.ReadBool();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 8:
                        if (field.Type == TType.Bool)
                        {
                            IncludeLinkedNotebooks = iprot.ReadBool();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 9:
                        if (field.Type == TType.Bool)
                        {
                            IncludeExpunged = iprot.ReadBool();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 10:
                        if (field.Type == TType.Bool)
                        {
                            IncludeNoteApplicationDataFullMap = iprot.ReadBool();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 12:
                        if (field.Type == TType.Bool)
                        {
                            IncludeResourceApplicationDataFullMap = iprot.ReadBool();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 13:
                        if (field.Type == TType.Bool)
                        {
                            IncludeNoteResourceApplicationDataFullMap = iprot.ReadBool();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 17:
                        if (field.Type == TType.Bool)
                        {
                            IncludeSharedNotes = iprot.ReadBool();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 16:
                        if (field.Type == TType.Bool)
                        {
                            OmitSharedNotebooks = iprot.ReadBool();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 11:
                        if (field.Type == TType.String)
                        {
                            RequireNoteContentClass = iprot.ReadString();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 15:
                        if (field.Type == TType.Set)
                        {
                            {
                                NotebookGuids = new THashSet <string>();
                                TSet _set44 = iprot.ReadSetBegin();
                                for (int _i45 = 0; _i45 < _set44.Count; ++_i45)
                                {
                                    string _elem46;
                                    _elem46 = iprot.ReadString();
                                    NotebookGuids.Add(_elem46);
                                }
                                iprot.ReadSetEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    default:
                        TProtocolUtil.Skip(iprot, field.Type);
                        break;
                    }
                    iprot.ReadFieldEnd();
                }
                iprot.ReadStructEnd();
            }
            finally
            {
                iprot.DecrementRecursionDepth();
            }
        }
    public void Read(TProtocol iprot)
    {
        iprot.IncrementRecursionDepth();
        try
        {
            TField field;
            iprot.ReadStructBegin();
            while (true)
            {
                field = iprot.ReadFieldBegin();
                if (field.Type == TType.Stop)
                {
                    break;
                }
                switch (field.ID)
                {
                case 2:
                    if (field.Type == TType.Set)
                    {
                        {
                            UpdatedAttrs = new THashSet <SquareChatMemberAttribute>();
                            TSet _set567 = iprot.ReadSetBegin();
                            for (int _i568 = 0; _i568 < _set567.Count; ++_i568)
                            {
                                SquareChatMemberAttribute _elem569;
                                _elem569 = (SquareChatMemberAttribute)iprot.ReadI32();
                                UpdatedAttrs.Add(_elem569);
                            }
                            iprot.ReadSetEnd();
                        }
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 3:
                    if (field.Type == TType.Struct)
                    {
                        ChatMember = new SquareChatMember();
                        ChatMember.Read(iprot);
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                default:
                    TProtocolUtil.Skip(iprot, field.Type);
                    break;
                }
                iprot.ReadFieldEnd();
            }
            iprot.ReadStructEnd();
        }
        finally
        {
            iprot.DecrementRecursionDepth();
        }
    }
Ejemplo n.º 27
0
        public static void Skip(TProtocol prot, TType type)
        {
            switch (type)
            {
            case TType.Bool:
                prot.ReadBool();
                break;

            case TType.Byte:
                prot.ReadByte();
                break;

            case TType.I16:
                prot.ReadI16();
                break;

            case TType.I32:
                prot.ReadI32();
                break;

            case TType.I64:
                prot.ReadI64();
                break;

            case TType.Double:
                prot.ReadDouble();
                break;

            case TType.String:
                // Don't try to decode the string, just skip it.
                prot.ReadBinary();
                break;

            case TType.Struct:
                prot.ReadStructBegin();
                while (true)
                {
                    TField field = prot.ReadFieldBegin();
                    if (field.Type == TType.Stop)
                    {
                        break;
                    }
                    Skip(prot, field.Type);
                    prot.ReadFieldEnd();
                }
                prot.ReadStructEnd();
                break;

            case TType.Map:
                TMap map = prot.ReadMapBegin();
                for (int i = 0; i < map.Count; i++)
                {
                    Skip(prot, map.KeyType);
                    Skip(prot, map.ValueType);
                }
                prot.ReadMapEnd();
                break;

            case TType.Set:
                TSet set = prot.ReadSetBegin();
                for (int i = 0; i < set.Count; i++)
                {
                    Skip(prot, set.ElementType);
                }
                prot.ReadSetEnd();
                break;

            case TType.List:
                TList list = prot.ReadListBegin();
                for (int i = 0; i < list.Count; i++)
                {
                    Skip(prot, list.ElementType);
                }
                prot.ReadListEnd();
                break;
            }
        }
Ejemplo n.º 28
0
        public void Read(TProtocol iprot)
        {
            iprot.IncrementRecursionDepth();
            try
            {
                TField field;
                iprot.ReadStructBegin();
                while (true)
                {
                    field = iprot.ReadFieldBegin();
                    if (field.Type == TType.Stop)
                    {
                        break;
                    }
                    switch (field.ID)
                    {
                    case 1:
                        if (field.Type == TType.Bool)
                        {
                            V_bool = iprot.ReadBool();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 2:
                        if (field.Type == TType.Byte)
                        {
                            V_i8 = iprot.ReadByte();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 3:
                        if (field.Type == TType.I16)
                        {
                            V_i16 = iprot.ReadI16();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 4:
                        if (field.Type == TType.I32)
                        {
                            V_i32 = iprot.ReadI32();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 5:
                        if (field.Type == TType.I64)
                        {
                            V_i64 = iprot.ReadI64();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 6:
                        if (field.Type == TType.Double)
                        {
                            V_double = iprot.ReadDouble();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 7:
                        if (field.Type == TType.String)
                        {
                            V_string = iprot.ReadString();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 8:
                        if (field.Type == TType.List)
                        {
                            {
                                V_list = new List <Variant>();
                                TList _list0 = iprot.ReadListBegin();
                                for (int _i1 = 0; _i1 < _list0.Count; ++_i1)
                                {
                                    Variant _elem2;
                                    _elem2 = new Variant();
                                    _elem2.Read(iprot);
                                    V_list.Add(_elem2);
                                }
                                iprot.ReadListEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 9:
                        if (field.Type == TType.Set)
                        {
                            {
                                V_set = new THashSet <Variant>();
                                TSet _set3 = iprot.ReadSetBegin();
                                for (int _i4 = 0; _i4 < _set3.Count; ++_i4)
                                {
                                    Variant _elem5;
                                    _elem5 = new Variant();
                                    _elem5.Read(iprot);
                                    V_set.Add(_elem5);
                                }
                                iprot.ReadSetEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 10:
                        if (field.Type == TType.Map)
                        {
                            {
                                V_map = new Dictionary <Variant, Variant>();
                                TMap _map6 = iprot.ReadMapBegin();
                                for (int _i7 = 0; _i7 < _map6.Count; ++_i7)
                                {
                                    Variant _key8;
                                    Variant _val9;
                                    _key8 = new Variant();
                                    _key8.Read(iprot);
                                    _val9 = new Variant();
                                    _val9.Read(iprot);
                                    V_map[_key8] = _val9;
                                }
                                iprot.ReadMapEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    default:
                        TProtocolUtil.Skip(iprot, field.Type);
                        break;
                    }
                    iprot.ReadFieldEnd();
                }
                iprot.ReadStructEnd();
            }
            finally
            {
                iprot.DecrementRecursionDepth();
            }
        }
Ejemplo n.º 29
0
        public void Read(TProtocol iprot)
        {
            iprot.IncrementRecursionDepth();
            try
            {
                TField field;
                iprot.ReadStructBegin();
                while (true)
                {
                    field = iprot.ReadFieldBegin();
                    if (field.Type == TType.Stop)
                    {
                        break;
                    }
                    switch (field.ID)
                    {
                    case 1:
                        if (field.Type == TType.List)
                        {
                            {
                                Int_set_list = new List <THashSet <int> >();
                                TList _list98 = iprot.ReadListBegin();
                                for (int _i99 = 0; _i99 < _list98.Count; ++_i99)
                                {
                                    THashSet <int> _elem100;
                                    {
                                        _elem100 = new THashSet <int>();
                                        TSet _set101 = iprot.ReadSetBegin();
                                        for (int _i102 = 0; _i102 < _set101.Count; ++_i102)
                                        {
                                            int _elem103;
                                            _elem103 = iprot.ReadI32();
                                            _elem100.Add(_elem103);
                                        }
                                        iprot.ReadSetEnd();
                                    }
                                    Int_set_list.Add(_elem100);
                                }
                                iprot.ReadListEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 2:
                        if (field.Type == TType.Map)
                        {
                            {
                                Map_int_strset = new Dictionary <int, THashSet <string> >();
                                TMap _map104 = iprot.ReadMapBegin();
                                for (int _i105 = 0; _i105 < _map104.Count; ++_i105)
                                {
                                    int _key106;
                                    THashSet <string> _val107;
                                    _key106 = iprot.ReadI32();
                                    {
                                        _val107 = new THashSet <string>();
                                        TSet _set108 = iprot.ReadSetBegin();
                                        for (int _i109 = 0; _i109 < _set108.Count; ++_i109)
                                        {
                                            string _elem110;
                                            _elem110 = iprot.ReadString();
                                            _val107.Add(_elem110);
                                        }
                                        iprot.ReadSetEnd();
                                    }
                                    Map_int_strset[_key106] = _val107;
                                }
                                iprot.ReadMapEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 3:
                        if (field.Type == TType.List)
                        {
                            {
                                Map_int_strset_list = new List <Dictionary <int, THashSet <string> > >();
                                TList _list111 = iprot.ReadListBegin();
                                for (int _i112 = 0; _i112 < _list111.Count; ++_i112)
                                {
                                    Dictionary <int, THashSet <string> > _elem113;
                                    {
                                        _elem113 = new Dictionary <int, THashSet <string> >();
                                        TMap _map114 = iprot.ReadMapBegin();
                                        for (int _i115 = 0; _i115 < _map114.Count; ++_i115)
                                        {
                                            int _key116;
                                            THashSet <string> _val117;
                                            _key116 = iprot.ReadI32();
                                            {
                                                _val117 = new THashSet <string>();
                                                TSet _set118 = iprot.ReadSetBegin();
                                                for (int _i119 = 0; _i119 < _set118.Count; ++_i119)
                                                {
                                                    string _elem120;
                                                    _elem120 = iprot.ReadString();
                                                    _val117.Add(_elem120);
                                                }
                                                iprot.ReadSetEnd();
                                            }
                                            _elem113[_key116] = _val117;
                                        }
                                        iprot.ReadMapEnd();
                                    }
                                    Map_int_strset_list.Add(_elem113);
                                }
                                iprot.ReadListEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    default:
                        TProtocolUtil.Skip(iprot, field.Type);
                        break;
                    }
                    iprot.ReadFieldEnd();
                }
                iprot.ReadStructEnd();
            }
            finally
            {
                iprot.DecrementRecursionDepth();
            }
        }
Ejemplo n.º 30
0
        public void Read(TProtocol iprot)
        {
            bool   isset_aborted = false;
            bool   isset_nosuch  = false;
            TField field;

            iprot.ReadStructBegin();
            while (true)
            {
                field = iprot.ReadFieldBegin();
                if (field.Type == TType.Stop)
                {
                    break;
                }
                switch (field.ID)
                {
                case 1:
                    if (field.Type == TType.Set)
                    {
                        {
                            Aborted = new THashSet <long>();
                            TSet _set217 = iprot.ReadSetBegin();
                            for (int _i218 = 0; _i218 < _set217.Count; ++_i218)
                            {
                                long _elem219 = 0;
                                _elem219 = iprot.ReadI64();
                                Aborted.Add(_elem219);
                            }
                            iprot.ReadSetEnd();
                        }
                        isset_aborted = true;
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                case 2:
                    if (field.Type == TType.Set)
                    {
                        {
                            Nosuch = new THashSet <long>();
                            TSet _set220 = iprot.ReadSetBegin();
                            for (int _i221 = 0; _i221 < _set220.Count; ++_i221)
                            {
                                long _elem222 = 0;
                                _elem222 = iprot.ReadI64();
                                Nosuch.Add(_elem222);
                            }
                            iprot.ReadSetEnd();
                        }
                        isset_nosuch = true;
                    }
                    else
                    {
                        TProtocolUtil.Skip(iprot, field.Type);
                    }
                    break;

                default:
                    TProtocolUtil.Skip(iprot, field.Type);
                    break;
                }
                iprot.ReadFieldEnd();
            }
            iprot.ReadStructEnd();
            if (!isset_aborted)
            {
                throw new TProtocolException(TProtocolException.INVALID_DATA);
            }
            if (!isset_nosuch)
            {
                throw new TProtocolException(TProtocolException.INVALID_DATA);
            }
        }
Ejemplo n.º 31
0
        public void Read(TProtocol iprot)
        {
            iprot.IncrementRecursionDepth();
            try
            {
                TField field;
                iprot.ReadStructBegin();
                while (true)
                {
                    field = iprot.ReadFieldBegin();
                    if (field.Type == TType.Stop)
                    {
                        break;
                    }
                    switch (field.ID)
                    {
                    case 1:
                        if (field.Type == TType.String)
                        {
                            SessionId = iprot.ReadString();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 2:
                        if (field.Type == TType.I32)
                        {
                            EntityType = iprot.ReadI32();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 3:
                        if (field.Type == TType.Set)
                        {
                            {
                                EntityIds = new THashSet <string>();
                                TSet _set77 = iprot.ReadSetBegin();
                                for (int _i78 = 0; _i78 < _set77.Count; ++_i78)
                                {
                                    string _elem79;
                                    _elem79 = iprot.ReadString();
                                    EntityIds.Add(_elem79);
                                }
                                iprot.ReadSetEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    default:
                        TProtocolUtil.Skip(iprot, field.Type);
                        break;
                    }
                    iprot.ReadFieldEnd();
                }
                iprot.ReadStructEnd();
            }
            finally
            {
                iprot.DecrementRecursionDepth();
            }
        }