public string PrintFullFile(FullFile file) { Debug.Assert(indentLevel == 0); builder = new StringBuilder(); PrintUsings(file.Usings); builder.AppendLine(); PrintNamespace(file.NamespaceContained); return builder.ToString(); }
internal static FullFile CreateFileForType(JabberCompiler.Model.IReadOnlyType type) { if (type.IsSingleton) throw new NotImplementedException(); string fileName = System.IO.Path.ChangeExtension(type.Name, "cs"); FullFile file = new FullFile() { Name = fileName, Usings = UsingStatement.DefaultUsings }; Namespace nspace = GetNamespace(DEFAULT_PROJECT_NAME); file.NamespaceContained = nspace; nspace.InnerClass = type; return file; }