mirror of
https://github.com/corda/corda.git
synced 2024-12-24 15:16:45 +00:00
Updated help text and corrected argument handling in IRS demo.
This commit is contained in:
parent
fad45eaa91
commit
8e9fc2d4c0
@ -87,8 +87,9 @@ fun main(args: Array<String>) {
|
|||||||
|
|
||||||
val role = options.valueOf(roleArg)!!
|
val role = options.valueOf(roleArg)!!
|
||||||
if(role == IRSDemoRole.Trade) {
|
if(role == IRSDemoRole.Trade) {
|
||||||
val tradeId: String? = options.valuesOf(tradeIdArg)[0]
|
val args : List<String> = options.valuesOf(tradeIdArg)
|
||||||
if (tradeId != null) {
|
if (args.size > 0) {
|
||||||
|
val tradeId = args[0]
|
||||||
if (runTrade(tradeId)) {
|
if (runTrade(tradeId)) {
|
||||||
exitProcess(0)
|
exitProcess(0)
|
||||||
} else {
|
} else {
|
||||||
@ -99,8 +100,9 @@ fun main(args: Array<String>) {
|
|||||||
exitProcess(1)
|
exitProcess(1)
|
||||||
}
|
}
|
||||||
} else if(role == IRSDemoRole.Date) {
|
} else if(role == IRSDemoRole.Date) {
|
||||||
val dateStr: String? = options.valueOf(dateArg)
|
val args = options.valuesOf(dateArg)
|
||||||
if(dateStr != null) {
|
if (args.size > 0) {
|
||||||
|
val dateStr = args[0]
|
||||||
runDateChange(dateStr)
|
runDateChange(dateStr)
|
||||||
} else {
|
} else {
|
||||||
println("Please provide a date")
|
println("Please provide a date")
|
||||||
@ -373,6 +375,6 @@ private fun createDefaultConfigFile(configFile: Path?, defaultLegalName: String)
|
|||||||
|
|
||||||
private fun printHelp() {
|
private fun printHelp() {
|
||||||
println("""
|
println("""
|
||||||
Please refer to the documentation that doesn't yet exist to learn how to run the demo.
|
Please refer to the documentation in docs/build/index.html to learn how to run the demo.
|
||||||
""".trimIndent())
|
""".trimIndent())
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user