package cn.flightfeather.supervision
|
|
import org.junit.Test
|
import java.util.*
|
import kotlin.properties.Delegates
|
|
class CommonTest {
|
|
@Test
|
fun foo1() {
|
val fName = Base64.getEncoder().encodeToString("2024年01月静安区工地-规范性评估与分析清单.xls".toByteArray())
|
val dName = String(Base64.getDecoder().decode(fName))
|
println(fName)
|
println(dName)
|
}
|
|
@Test
|
fun annotationTest() {
|
"name" + "1"
|
mapOf<String, String>("name" to "1")
|
}
|
|
@Test
|
fun findStr() {
|
val str = "http://114.233.144.555:9006/asdasd/asdasd"
|
val url = str.split("://")[1].split("/")[0]
|
val newStr = str.replace(url, "224.55.2.12:8085")
|
// val i1 = str.indexOf("://")
|
// val i2 = str.indexOf("/")
|
println(str)
|
println(newStr)
|
}
|
}
|