我对 Scala 真的很陌生,我什至无法连接字符串。这是我的代码:
object RandomData {
private[this] val bag = new scala.util.Random
def apply(sensorId: String, stamp: Long, size: Int): String = {
var cpt: Int = 0
var data: String = "test"
repeat(10) {
data += "_test"
}
return data
}
}
我得到了错误:
type mismatch;
found : Unit
required: com.excilys.ebi.gatling.core.structure.ChainBuilder
我究竟做错了什么 ??