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.I64)
                        {
                            Id = iprot.ReadI64();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

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

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

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

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

                    case 6:
                        if (field.Type == TType.List)
                        {
                            {
                                KeyValueMaps = new List <TDDIKeyValueMapRef>();
                                TList _list556 = iprot.ReadListBegin();
                                for (int _i557 = 0; _i557 < _list556.Count; ++_i557)
                                {
                                    TDDIKeyValueMapRef _elem558;
                                    _elem558 = new TDDIKeyValueMapRef();
                                    _elem558.Read(iprot);
                                    KeyValueMaps.Add(_elem558);
                                }
                                iprot.ReadListEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

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

                    case 8:
                        if (field.Type == TType.List)
                        {
                            {
                                FailureAnalysisArtifacts = new List <TDDIAbstractFailureAnalysisArtifactRef>();
                                TList _list559 = iprot.ReadListBegin();
                                for (int _i560 = 0; _i560 < _list559.Count; ++_i560)
                                {
                                    TDDIAbstractFailureAnalysisArtifactRef _elem561;
                                    _elem561 = new TDDIAbstractFailureAnalysisArtifactRef();
                                    _elem561.Read(iprot);
                                    FailureAnalysisArtifacts.Add(_elem561);
                                }
                                iprot.ReadListEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 9:
                        if (field.Type == TType.List)
                        {
                            {
                                FMEAArtifacts = new List <TDDIAbstractFMEAArtifactRef>();
                                TList _list562 = iprot.ReadListBegin();
                                for (int _i563 = 0; _i563 < _list562.Count; ++_i563)
                                {
                                    TDDIAbstractFMEAArtifactRef _elem564;
                                    _elem564 = new TDDIAbstractFMEAArtifactRef();
                                    _elem564.Read(iprot);
                                    FMEAArtifacts.Add(_elem564);
                                }
                                iprot.ReadListEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    default:
                        TProtocolUtil.Skip(iprot, field.Type);
                        break;
                    }
                    iprot.ReadFieldEnd();
                }
                iprot.ReadStructEnd();
            }
            finally
            {
                iprot.DecrementRecursionDepth();
            }
        }
Example #2
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.I64)
                        {
                            Id = iprot.ReadI64();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

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

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

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

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

                    case 6:
                        if (field.Type == TType.List)
                        {
                            {
                                KeyValueMaps = new List <TDDIKeyValueMapRef>();
                                TList _list544 = iprot.ReadListBegin();
                                for (int _i545 = 0; _i545 < _list544.Count; ++_i545)
                                {
                                    TDDIKeyValueMapRef _elem546;
                                    _elem546 = new TDDIKeyValueMapRef();
                                    _elem546.Read(iprot);
                                    KeyValueMaps.Add(_elem546);
                                }
                                iprot.ReadListEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

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

                    case 8:
                        if (field.Type == TType.List)
                        {
                            {
                                FailureAnalysisArtifacts = new List <TDDIAbstractFailureAnalysisArtifactRef>();
                                TList _list547 = iprot.ReadListBegin();
                                for (int _i548 = 0; _i548 < _list547.Count; ++_i548)
                                {
                                    TDDIAbstractFailureAnalysisArtifactRef _elem549;
                                    _elem549 = new TDDIAbstractFailureAnalysisArtifactRef();
                                    _elem549.Read(iprot);
                                    FailureAnalysisArtifacts.Add(_elem549);
                                }
                                iprot.ReadListEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 9:
                        if (field.Type == TType.List)
                        {
                            {
                                FMEAArtifacts = new List <TDDIAbstractFMEAArtifactRef>();
                                TList _list550 = iprot.ReadListBegin();
                                for (int _i551 = 0; _i551 < _list550.Count; ++_i551)
                                {
                                    TDDIAbstractFMEAArtifactRef _elem552;
                                    _elem552 = new TDDIAbstractFMEAArtifactRef();
                                    _elem552.Read(iprot);
                                    FMEAArtifacts.Add(_elem552);
                                }
                                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.I64)
                        {
                            Id = iprot.ReadI64();
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

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

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

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

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

                    case 6:
                        if (field.Type == TType.List)
                        {
                            {
                                KeyValueMaps = new List <TDDIKeyValueMapRef>();
                                TList _list528 = iprot.ReadListBegin();
                                for (int _i529 = 0; _i529 < _list528.Count; ++_i529)
                                {
                                    TDDIKeyValueMapRef _elem530;
                                    _elem530 = new TDDIKeyValueMapRef();
                                    _elem530.Read(iprot);
                                    KeyValueMaps.Add(_elem530);
                                }
                                iprot.ReadListEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

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

                    case 8:
                        if (field.Type == TType.List)
                        {
                            {
                                FailureAnalysisArtifacts = new List <TDDIAbstractFailureAnalysisArtifactRef>();
                                TList _list531 = iprot.ReadListBegin();
                                for (int _i532 = 0; _i532 < _list531.Count; ++_i532)
                                {
                                    TDDIAbstractFailureAnalysisArtifactRef _elem533;
                                    _elem533 = new TDDIAbstractFailureAnalysisArtifactRef();
                                    _elem533.Read(iprot);
                                    FailureAnalysisArtifacts.Add(_elem533);
                                }
                                iprot.ReadListEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 9:
                        if (field.Type == TType.List)
                        {
                            {
                                FMEAArtifacts = new List <TDDIAbstractFMEAArtifactRef>();
                                TList _list534 = iprot.ReadListBegin();
                                for (int _i535 = 0; _i535 < _list534.Count; ++_i535)
                                {
                                    TDDIAbstractFMEAArtifactRef _elem536;
                                    _elem536 = new TDDIAbstractFMEAArtifactRef();
                                    _elem536.Read(iprot);
                                    FMEAArtifacts.Add(_elem536);
                                }
                                iprot.ReadListEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

                    case 11:
                        if (field.Type == TType.List)
                        {
                            {
                                ParticipantPackages = new List <TDDIAbstractFMEAPackageRef>();
                                TList _list537 = iprot.ReadListBegin();
                                for (int _i538 = 0; _i538 < _list537.Count; ++_i538)
                                {
                                    TDDIAbstractFMEAPackageRef _elem539;
                                    _elem539 = new TDDIAbstractFMEAPackageRef();
                                    _elem539.Read(iprot);
                                    ParticipantPackages.Add(_elem539);
                                }
                                iprot.ReadListEnd();
                            }
                        }
                        else
                        {
                            TProtocolUtil.Skip(iprot, field.Type);
                        }
                        break;

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