コード例 #1
0
        private void WriteClass(RapClass rapClass, StreamWriter headerWriter = null)
        {
            var writer = headerWriter ?? _writer;

            writer.Write(rapClass.ToConfigFormat());

            if (rapClass.Entries == 0)
            {
                writer.WriteLine("};");
                return;
            }

            writer.WriteLine();
            WriteEntriesFromClass(rapClass, writer);

            writer.WriteLine("};");
        }
コード例 #2
0
        private void WriteChildrenClass(RapClass child, StreamWriter headerWriter = null)
        {
            var writer = headerWriter ?? _writer;

            writer.Write(Padding + child.ToConfigFormat());

            if (child.Entries != 0)
            {
                writer.WriteLine();

                _paddingSize++;
                WriteEntriesFromClass(child, writer);
                _paddingSize--;

                writer.WriteLine(Padding + "};");
            }
            else
            {
                writer.Write(" };");
            }
        }