Ejemplo n.º 1
0
        public override void WriteGen(APGen gen, XmlWriter writer)
        {
            if (Name != null)
            {
                writer.WriteStartElement("sectionGroup");
                writer.WriteAttributeString("name", Name);
                if (TypeName != null && TypeName != "" && TypeName != "Symber.Web.Compilation.Gen.APGenSectionGroup")
                {
                    writer.WriteAttributeString("type", TypeName);
                }
            }
            else
            {
                writer.WriteStartElement("genSections");
            }

            foreach (GenInfoCollection col in new object[] { Sections, Groups })
            {
                foreach (string key in col)
                {
                    GenInfo info = col[key];
                    if (info.HasDataContent(gen))
                    {
                        info.WriteGen(gen, writer);
                    }
                }
            }

            writer.WriteEndElement();
        }
Ejemplo n.º 2
0
 internal void WriteContent(XmlWriter writer, APGen gen, bool writeElement)
 {
     foreach (GenInfoCollection col in new object[] { Sections, Groups })
     {
         foreach (string key in col)
         {
             GenInfo info = col[key];
             if (info.HasDataContent(gen))
             {
                 info.WriteData(gen, writer);
             }
         }
     }
 }
Ejemplo n.º 3
0
 public override bool HasDataContent(APGen gen)
 {
     foreach (GenInfoCollection col in new object[] { Sections, Groups })
     {
         foreach (string key in col)
         {
             GenInfo info = col[key];
             if (info.HasDataContent(gen))
             {
                 return(true);
             }
         }
     }
     return(false);
 }