1
0
Fork 0
mirror of https://github.com/ethauvin/kobalt.git synced 2025-04-25 16:07:12 -07:00
This commit is contained in:
Erik C. Thauvin 2017-05-03 20:13:13 -07:00
parent e4650dd953
commit 407d2bb436

View file

@ -62,7 +62,7 @@ class JavadocConfig(val project: Project) {
} }
} }
private fun addOptions(option: String, first: String, second: String) { private fun addPair(option: String, first: String, second: String) {
if (first.isNotEmpty() && second.isNotEmpty()) { if (first.isNotEmpty() && second.isNotEmpty()) {
args.add("-$option") args.add("-$option")
args.add("\"$first\"") args.add("\"$first\"")
@ -320,8 +320,8 @@ class JavadocConfig(val project: Project) {
*/ */
var title: String = "" var title: String = ""
set(value) { set(value) {
addString("windowtitle", value) windowTitle = value
addString("doctitle", value) docTitle = value
} }
/** /**
@ -543,12 +543,12 @@ class JavadocConfig(val project: Project) {
/** /**
* @see <a href="http://docs.oracle.com/javase/8/docs/technotes/tools/windows/javadoc.html#CHDIGGII">-group</a> * @see <a href="http://docs.oracle.com/javase/8/docs/technotes/tools/windows/javadoc.html#CHDIGGII">-group</a>
*/ */
fun group(groupHeading: String, packagePattern: String) = addOptions("group", groupHeading, packagePattern) fun group(groupHeading: String, packagePattern: String) = addPair("group", groupHeading, packagePattern)
/** /**
* @see <a href="http://docs.oracle.com/javase/8/docs/technotes/tools/windows/javadoc.html#CHDFIIJH">-linkoffline</a> * @see <a href="http://docs.oracle.com/javase/8/docs/technotes/tools/windows/javadoc.html#CHDFIIJH">-linkoffline</a>
*/ */
fun linkOffline(extdocURL: String, packagelistLoc: String) = addOptions("linkoffline", extdocURL, packagelistLoc) fun linkOffline(extdocURL: String, packagelistLoc: String) = addPair("linkoffline", extdocURL, packagelistLoc)
/** /**
* @see <a href="http://docs.oracle.com/javase/8/docs/technotes/tools/windows/javadoc.html#CHDEDJFI">-link</a> * @see <a href="http://docs.oracle.com/javase/8/docs/technotes/tools/windows/javadoc.html#CHDEDJFI">-link</a>
@ -582,6 +582,7 @@ fun main(args: Array<String>) {
} }
val config = JavadocConfig(Project()) val config = JavadocConfig(Project())
config.title = "This is a test."
config.verbose = true config.verbose = true
config.quiet = false config.quiet = false
config.links("http://docs.oracle.com/javase/8/docs/api/") config.links("http://docs.oracle.com/javase/8/docs/api/")