aboutsummaryrefslogtreecommitdiff
path: root/src/main.kt
diff options
context:
space:
mode:
authorDmitry Jemerov <yole@jetbrains.com>2015-02-25 19:03:51 +0100
committerDmitry Jemerov <yole@jetbrains.com>2015-02-25 19:03:51 +0100
commit184a24c93e0939c5a9ceb10cf3c3992f11165219 (patch)
treef4334b51d9f2bc021d5af55aca3e0be9e8ceec37 /src/main.kt
parent29e48dcbf30ac16013d9c8951e4fa088e8d9b016 (diff)
downloaddokka-184a24c93e0939c5a9ceb10cf3c3992f11165219.tar.gz
dokka-184a24c93e0939c5a9ceb10cf3c3992f11165219.tar.bz2
dokka-184a24c93e0939c5a9ceb10cf3c3992f11165219.zip
resolve references through single map from signature to DocumentationNode (enables cross-language references)
Diffstat (limited to 'src/main.kt')
-rw-r--r--src/main.kt8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/main.kt b/src/main.kt
index a48b4af6..242ac85a 100644
--- a/src/main.kt
+++ b/src/main.kt
@@ -195,8 +195,8 @@ fun buildDocumentationModule(environment: AnalysisEnvironment,
val fragments = fragmentFiles.map { session.getPackageFragment(it.getPackageFqName()) }.filterNotNull().distinct()
val moduleContent = Content()
- val pendingReferences = arrayListOf<PendingDocumentationReference>()
- val documentationBuilder = DocumentationBuilder(session, options, pendingReferences, logger)
+ val refGraph = NodeReferenceGraph()
+ val documentationBuilder = DocumentationBuilder(session, options, refGraph, logger)
for (include in includes) {
val file = File(include)
if (file.exists()) {
@@ -215,10 +215,10 @@ fun buildDocumentationModule(environment: AnalysisEnvironment,
}
val javaFiles = environment.getJavaSourceFiles().filter(filesToDocumentFilter)
- val javaDocumentationBuilder = JavaDocumentationBuilder(options, pendingReferences)
+ val javaDocumentationBuilder = JavaDocumentationBuilder(options, refGraph)
javaFiles.map { javaDocumentationBuilder.appendFile(it, documentationModule) }
- pendingReferences.forEach { it.resolve() }
+ refGraph.resolveReferences()
documentationModule
}