private static List <Declaration> BuildDeclarations() { List <Declaration> list = new List <Declaration>(6); list.Add(BaseInterleaver.GetDeclaration()); list.Add(OpenXmlTableGridModel.GetDeclaration()); list.Add(OpenXmlTableRowPropertiesModel.GetDeclaration()); list.Add(OpenXmlBorderPropertiesModel.GetDeclaration()); list.Add(HeaderFooterReferences.GetDeclaration()); return(list); }
public override void Deserialize(IntermediateFormatReader reader) { base.Deserialize(reader); reader.RegisterDeclaration(OpenXmlTableGridModel.GetDeclaration()); while (reader.NextMember()) { MemberName memberName = reader.CurrentMember.MemberName; if (memberName == MemberName.Columns) { this._columns = reader.ReadListOfPrimitives <int>(); } else { WordOpenXmlUtils.FailSerializable(); } } }
public override void Serialize(IntermediateFormatWriter writer) { base.Serialize(writer); writer.RegisterDeclaration(OpenXmlTableGridModel.GetDeclaration()); while (writer.NextMember()) { MemberName memberName = writer.CurrentMember.MemberName; if (memberName == MemberName.Columns) { writer.WriteListOfPrimitives(this._columns); } else { WordOpenXmlUtils.FailSerializable(); } } }