public void Write(TProtocol oprot) { oprot.IncrementRecursionDepth(); try { TStruct struc = new TStruct("TDDICauseUnion"); oprot.WriteStructBegin(struc); TField field = new TField(); if (Cause != null && __isset.Cause) { field.Name = "Cause"; field.Type = TType.Struct; field.ID = 1; oprot.WriteFieldBegin(field); Cause.Write(oprot); oprot.WriteFieldEnd(); } if (Gate != null && __isset.Gate) { field.Name = "Gate"; field.Type = TType.Struct; field.ID = 2; oprot.WriteFieldBegin(field); Gate.Write(oprot); oprot.WriteFieldEnd(); } oprot.WriteFieldStop(); oprot.WriteStructEnd(); } finally { oprot.DecrementRecursionDepth(); } }
public void Write(TProtocol oprot) { oprot.IncrementRecursionDepth(); try { TStruct struc = new TStruct("TDDIInterfaceFailurePropagation"); oprot.WriteStructBegin(struc); TField field = new TField(); if (__isset.Id) { field.Name = "Id"; field.Type = TType.I64; field.ID = 1; oprot.WriteFieldBegin(field); oprot.WriteI64(Id); oprot.WriteFieldEnd(); } if (Name != null && __isset.Name) { field.Name = "Name"; field.Type = TType.String; field.ID = 2; oprot.WriteFieldBegin(field); oprot.WriteString(Name); oprot.WriteFieldEnd(); } if (Description != null && __isset.Description) { field.Name = "Description"; field.Type = TType.String; field.ID = 3; oprot.WriteFieldBegin(field); oprot.WriteString(Description); oprot.WriteFieldEnd(); } if (__isset.IsCitation) { field.Name = "IsCitation"; field.Type = TType.Bool; field.ID = 4; oprot.WriteFieldBegin(field); oprot.WriteBool(IsCitation); oprot.WriteFieldEnd(); } if (__isset.IsAbstract) { field.Name = "IsAbstract"; field.Type = TType.Bool; field.ID = 5; oprot.WriteFieldBegin(field); oprot.WriteBool(IsAbstract); oprot.WriteFieldEnd(); } if (KeyValueMaps != null && __isset.KeyValueMaps) { field.Name = "KeyValueMaps"; field.Type = TType.List; field.ID = 6; oprot.WriteFieldBegin(field); { oprot.WriteListBegin(new TList(TType.Struct, KeyValueMaps.Count)); foreach (TDDIKeyValueMapRef _iter463 in KeyValueMaps) { _iter463.Write(oprot); } oprot.WriteListEnd(); } oprot.WriteFieldEnd(); } if (CitedElement != null && __isset.CitedElement) { field.Name = "CitedElement"; field.Type = TType.Struct; field.ID = 7; oprot.WriteFieldBegin(field); CitedElement.Write(oprot); oprot.WriteFieldEnd(); } if (Cause != null && __isset.Cause) { field.Name = "Cause"; field.Type = TType.Struct; field.ID = 8; oprot.WriteFieldBegin(field); Cause.Write(oprot); oprot.WriteFieldEnd(); } if (Effect != null && __isset.Effect) { field.Name = "Effect"; field.Type = TType.Struct; field.ID = 9; oprot.WriteFieldBegin(field); Effect.Write(oprot); oprot.WriteFieldEnd(); } oprot.WriteFieldStop(); oprot.WriteStructEnd(); } finally { oprot.DecrementRecursionDepth(); } }