Exemplo n.º 1
0
        public Elements TypeSender()
        {
            foreach (var type in types)
            {
                if (type.IsClass)
                {
                    ClassWriter classwriter = new ClassWriter(type, elements);
                    classwriter.Write();
                    elements = classwriter.elements;
                }
                else if (type.IsEnum)
                {
                    EnumWriter enumwriter = new EnumWriter(type, elements);
                    enumwriter.Write();
                    elements = enumwriter.elements;
                }
                else
                {
                    StructWriter structwriter = new StructWriter(type, elements);
                    structwriter.Write();
                    elements = structwriter.element;
                }
            }

            return(elements);
        }
Exemplo n.º 2
0
 public void TypeSender()
 {
     foreach (var type in types)
     {
         if (type.IsClass)
         {
             ClassWriter classwriter = new ClassWriter(type, elements);
             classwriter.Write();
         }
         else if (type.IsEnum)
         {
             EnumWriter enumwriter = new EnumWriter(type, elements);
             enumwriter.Write();
         }
         else
         {
             StructWriter structwriter = new StructWriter(type, elements);
             structwriter.Write();
         }
     }
 }