当我使用任何类型的进度指示器(例如)CircularProgressIndicator()或LinearProgressIndicator()我的应用程序崩溃时:
java.lang.NoSuchMethodError: No virtual method at(Ljava/lang/Object;I)
Landroidx/compose/animation/core/KeyframesSpec$KeyframeEntity; in class
Landroidx/compose/animation/core/KeyframesSpec$KeyframesSpecConfig; or its super classes
(declaration of 'androidx.compose.animation.core.KeyframesSpec$KeyframesSpecConfig' appears in
/data/app/~~rlFP4ThDS2yjsD1Xsh1cWQ==/es.jvbabi.vplanplus-6LDitHOwZpwGZt8Ywx6lFQ==/base.apk)
at androidx.compose.material3.ProgressIndicatorKt$CircularProgressIndicator$endAngle$1.invoke(ProgressIndicator.kt:302)
at androidx.compose.material3.ProgressIndicatorKt$CircularProgressIndicator$endAngle$1.invoke(ProgressIndicator.kt:300)
Run Code Online (Sandbox Code Playgroud)
这些是我与此问题相关的依赖项:
implementation("androidx.core:core-ktx:1.12.0")
implementation("androidx.lifecycle:lifecycle-runtime-ktx:2.6.2")
implementation("androidx.activity:activity-compose:1.8.0")
implementation("androidx.compose.ui:ui")
implementation("androidx.compose.material3:material3")
Run Code Online (Sandbox Code Playgroud)
无论我把它们放在哪里,它们都会导致应用程序崩溃。
当我使用Spring 初始化创建新项目时,Gradle 不会构建该项目。我使用 IntelliJ IDEA。
错误信息是
* Exception is:
org.gradle.cache.CacheOpenException: Could not open init generic class cache for initialization script '/tmp/ijmapper.gradle' (/home/julius/.gradle/caches/7.6.1/scripts/dnnmnny7cynyzgkf00s30jlld).
at org.gradle.cache.internal.DefaultPersistentDirectoryStore.open(DefaultPersistentDirectoryStore.java:91)
... 166+ more
Caused by: java.lang.IllegalArgumentException: Unsupported class file major version 64
Run Code Online (Sandbox Code Playgroud)
我用这个表查了一下,它是java 20。问题是,我没有选择Java-20,我选择了Java-17。最重要的是,我还无法在我的 Linux 机器上安装 Java-20。
我收到此错误:
Syntax Error: ambiguous indirect export
在 Firefox 中。可惜谷歌搜不到任何东西……
<script type="module">
import {someFunctionINeed} from "./js/functions.js";
...
</script>
Run Code Online (Sandbox Code Playgroud)
export function someFunctionINeed(cname) { ... }
Run Code Online (Sandbox Code Playgroud)
tsconfig.json:"compilerOptions": {
"module": "commonjs",
"target": "es5",
"sourceMap": true,
"watch": true,
"removeComments": true
}
Run Code Online (Sandbox Code Playgroud)
package.json:"type": "module"
Run Code Online (Sandbox Code Playgroud)
我错过了什么?
我需要一个 kotlin 中的 HTTP GET 请求的示例。我有一个数据库,并且已经使用 API 来将信息获取到服务器。作为最终结果,我需要在 android 布局中的“editText”内呈现 API json。建议?我已经有这个代码:
fun fetchJson(){
val url = "http://localhost:8080/matematica3/naoAutomatica/get"
val request = Request.Builder().url(url).build()
val client = OkHttpClient()
client.newCall(request).enqueue(object : Callback {
override fun onResponse(call: Call, response: Response) {
val body = response.body?.string()
println(body)
}
override fun onFailure(call: Call, e: IOException) {
println("Falhou")
}
}
}
Run Code Online (Sandbox Code Playgroud) kotlin ×3
gradle ×2
android ×1
html ×1
java ×1
javascript ×1
module ×1
okhttp ×1
spring ×1
typescript ×1
web-services ×1