diff options
Diffstat (limited to 'ant/src/dokka.kt')
-rw-r--r-- | ant/src/dokka.kt | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/ant/src/dokka.kt b/ant/src/dokka.kt index 882dbdb7..d78980f8 100644 --- a/ant/src/dokka.kt +++ b/ant/src/dokka.kt @@ -37,7 +37,7 @@ class DokkaAntTask(): Task() { } public fun setClasspathRef(ref: Reference) { - compileClasspath.createPath().setRefid(ref) + compileClasspath.createPath().refid = ref } public fun setSrc(src: Path) { @@ -45,7 +45,7 @@ class DokkaAntTask(): Task() { } public fun setSrcRef(ref: Reference) { - sourcePath.createPath().setRefid(ref) + sourcePath.createPath().refid = ref } public fun setSamples(samples: Path) { @@ -53,7 +53,7 @@ class DokkaAntTask(): Task() { } public fun setSamplesRef(ref: Reference) { - samplesPath.createPath().setRefid(ref) + samplesPath.createPath().refid = ref } public fun setInclude(include: Path) { @@ -67,7 +67,7 @@ class DokkaAntTask(): Task() { } override fun execute() { - if (sourcePath.list().size() == 0) { + if (sourcePath.list().size == 0) { throw BuildException("At least one source path needs to be specified") } if (moduleName == null) { @@ -85,11 +85,11 @@ class DokkaAntTask(): Task() { if (url == null) { throw BuildException("Path attribute of a <sourceLink> element is required") } - SourceLinkDefinition(File(path).getCanonicalFile().getAbsolutePath(), url, it.lineSuffix) + SourceLinkDefinition(File(path).canonicalFile.absolutePath, url, it.lineSuffix) } - val url = javaClass<DokkaAntTask>().getResource("/org/jetbrains/dokka/ant/DokkaAntTask.class") - val jarRoot = url.getPath().substringBefore("!/").removePrefix("file:") + val url = DokkaAntTask::class.java.getResource("/org/jetbrains/dokka/ant/DokkaAntTask.class") + val jarRoot = url.path.substringBefore("!/").removePrefix("file:") val generator = DokkaGenerator( AntLogger(this), |