comparison trunk/src/docgen/document/generator.d @ 729:ec8dd7b8bf0c

Updated graph type.
author Jari-Matti M?kel? <jmjm@iki.fi>
date Sun, 03 Feb 2008 19:43:53 +0200
parents cb8edb09108a
children
comparison
equal deleted inserted replaced
728:41cad5ca4863 729:ec8dd7b8bf0c
16 import tango.io.FilePath; 16 import tango.io.FilePath;
17 import tango.io.FileScan; 17 import tango.io.FileScan;
18 debug import tango.io.Stdout; 18 debug import tango.io.Stdout;
19 19
20 20
21 alias void delegate(ref Module[], ref Edge[], ref Vertex[char[]]) ParserDg; 21 alias void delegate(ref Module[], ref DepGraph) ParserDg;
22 22
23 abstract class DefaultDocGenerator : DocGenerator { 23 abstract class DefaultDocGenerator : DocGenerator {
24 protected: 24 protected:
25 25
26 DocFormat docFormat; 26 DocFormat docFormat;
35 PageWriterFactory pageFactory; 35 PageWriterFactory pageFactory;
36 ListingWriterFactory listingFactory; 36 ListingWriterFactory listingFactory;
37 ModuleDocWriterFactory moduleDocFactory; 37 ModuleDocWriterFactory moduleDocFactory;
38 38
39 Module[] modules; 39 Module[] modules;
40 Edge[] edges; 40 DepGraph depGraph;
41 Vertex[char[]] vertices;
42 41
43 public: 42 public:
44 43
45 this(DocGeneratorOptions options, ParserDg parser) { 44 this(DocGeneratorOptions options, ParserDg parser) {
46 m_options = options; 45 m_options = options;
98 FileOutput outputFile(char[] fname) { 97 FileOutput outputFile(char[] fname) {
99 return new FileOutput(outPath(fname)); 98 return new FileOutput(outPath(fname));
100 } 99 }
101 100
102 void parseSources() { 101 void parseSources() {
103 m_parser(modules, edges, vertices); 102 depGraph = new DepGraph();
103 m_parser(modules, depGraph);
104 } 104 }
105 105
106 //--- 106 //---
107 107
108 void writeSimpleFile(char[] fname, void delegate() dg) { 108 void writeSimpleFile(char[] fname, void delegate() dg) {