public void Write(TProtocol oprot) { oprot.IncrementRecursionDepth(); try { TStruct struc = new TStruct("FileCryptoMetaData"); oprot.WriteStructBegin(struc); TField field = new TField(); field.Name = "encryption_algorithm"; field.Type = TType.Struct; field.ID = 1; oprot.WriteFieldBegin(field); Encryption_algorithm.Write(oprot); oprot.WriteFieldEnd(); if (Key_metadata != null && __isset.key_metadata) { field.Name = "key_metadata"; field.Type = TType.String; field.ID = 2; oprot.WriteFieldBegin(field); oprot.WriteBinary(Key_metadata); oprot.WriteFieldEnd(); } oprot.WriteFieldStop(); oprot.WriteStructEnd(); } finally { oprot.DecrementRecursionDepth(); } }
public void Write(TProtocol oprot) { oprot.IncrementRecursionDepth(); try { TStruct struc = new TStruct("FileMetaData"); oprot.WriteStructBegin(struc); TField field = new TField(); field.Name = "version"; field.Type = TType.I32; field.ID = 1; oprot.WriteFieldBegin(field); oprot.WriteI32(Version); oprot.WriteFieldEnd(); field.Name = "schema"; field.Type = TType.List; field.ID = 2; oprot.WriteFieldBegin(field); { oprot.WriteListBegin(new TList(TType.Struct, Schema.Count)); foreach (SchemaElement _iter60 in Schema) { _iter60.Write(oprot); } oprot.WriteListEnd(); } oprot.WriteFieldEnd(); field.Name = "num_rows"; field.Type = TType.I64; field.ID = 3; oprot.WriteFieldBegin(field); oprot.WriteI64(Num_rows); oprot.WriteFieldEnd(); field.Name = "row_groups"; field.Type = TType.List; field.ID = 4; oprot.WriteFieldBegin(field); { oprot.WriteListBegin(new TList(TType.Struct, Row_groups.Count)); foreach (RowGroup _iter61 in Row_groups) { _iter61.Write(oprot); } oprot.WriteListEnd(); } oprot.WriteFieldEnd(); if (Key_value_metadata != null && __isset.key_value_metadata) { field.Name = "key_value_metadata"; field.Type = TType.List; field.ID = 5; oprot.WriteFieldBegin(field); { oprot.WriteListBegin(new TList(TType.Struct, Key_value_metadata.Count)); foreach (KeyValue _iter62 in Key_value_metadata) { _iter62.Write(oprot); } oprot.WriteListEnd(); } oprot.WriteFieldEnd(); } if (Created_by != null && __isset.created_by) { field.Name = "created_by"; field.Type = TType.String; field.ID = 6; oprot.WriteFieldBegin(field); oprot.WriteString(Created_by); oprot.WriteFieldEnd(); } if (Column_orders != null && __isset.column_orders) { field.Name = "column_orders"; field.Type = TType.List; field.ID = 7; oprot.WriteFieldBegin(field); { oprot.WriteListBegin(new TList(TType.Struct, Column_orders.Count)); foreach (ColumnOrder _iter63 in Column_orders) { _iter63.Write(oprot); } oprot.WriteListEnd(); } oprot.WriteFieldEnd(); } if (Encryption_algorithm != null && __isset.encryption_algorithm) { field.Name = "encryption_algorithm"; field.Type = TType.Struct; field.ID = 8; oprot.WriteFieldBegin(field); Encryption_algorithm.Write(oprot); oprot.WriteFieldEnd(); } if (Footer_signing_key_metadata != null && __isset.footer_signing_key_metadata) { field.Name = "footer_signing_key_metadata"; field.Type = TType.String; field.ID = 9; oprot.WriteFieldBegin(field); oprot.WriteBinary(Footer_signing_key_metadata); oprot.WriteFieldEnd(); } oprot.WriteFieldStop(); oprot.WriteStructEnd(); } finally { oprot.DecrementRecursionDepth(); } }