Skip to content

Commit

Permalink
Merge pull request #851 from simple-robot/fix-support
Browse files Browse the repository at this point in the history
修复部分面向Java未被正确隐藏/转化的挂起函数
  • Loading branch information
ForteScarlet authored Jun 13, 2024
2 parents a4542ff + 70e86fe commit 1cb5b01
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 6 deletions.
9 changes: 6 additions & 3 deletions simbot-api/api/simbot-api.api
Original file line number Diff line number Diff line change
Expand Up @@ -1731,8 +1731,11 @@ public final class love/forte/simbot/event/TypedJBlockEventListener$Companion {

public abstract class love/forte/simbot/message/AggregatedMessageReceipt : java/lang/Iterable, kotlin/jvm/internal/markers/KMappedMarker, love/forte/simbot/message/StandardMessageReceipt {
public fun <init> ()V
public fun delete ([Llove/forte/simbot/ability/DeleteOption;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
public fun deleteAll ([Llove/forte/simbot/ability/DeleteOption;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
public synthetic fun delete ([Llove/forte/simbot/ability/DeleteOption;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
public synthetic fun deleteAll ([Llove/forte/simbot/ability/DeleteOption;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
public fun deleteAllAsync ([Llove/forte/simbot/ability/DeleteOption;)Ljava/util/concurrent/CompletableFuture;
public fun deleteAllBlocking ([Llove/forte/simbot/ability/DeleteOption;)I
public fun deleteAllReserve ([Llove/forte/simbot/ability/DeleteOption;)Llove/forte/simbot/suspendrunner/reserve/SuspendReserve;
public abstract fun get (I)Llove/forte/simbot/message/SingleMessageReceipt;
public abstract fun getSize ()I
public fun iterator ()Ljava/util/Iterator;
Expand Down Expand Up @@ -1897,7 +1900,7 @@ public abstract interface class love/forte/simbot/message/Message$Element : love
}

public abstract interface class love/forte/simbot/message/MessageContent : love/forte/simbot/ability/DeleteSupport {
public abstract fun delete ([Llove/forte/simbot/ability/DeleteOption;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
public abstract synthetic fun delete ([Llove/forte/simbot/ability/DeleteOption;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
public abstract fun getId ()Llove/forte/simbot/common/id/ID;
public abstract fun getMessages ()Llove/forte/simbot/message/Messages;
public abstract fun getPlainText ()Ljava/lang/String;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Project https://github.com/simple-robot/simpler-robot
* Email [email protected]
*
* This file is part of the Simple Robot Library.
* This file is part of the Simple Robot Library (Alias: simple-robot, simbot, etc.).
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
Expand All @@ -27,6 +27,7 @@ import love.forte.simbot.ability.DeleteFailureException
import love.forte.simbot.ability.DeleteOption
import love.forte.simbot.ability.DeleteSupport
import love.forte.simbot.common.id.ID
import kotlin.jvm.JvmSynthetic


/**
Expand Down Expand Up @@ -81,6 +82,7 @@ public interface MessageContent : DeleteSupport {
* @throws DeleteFailureException 删除行为失败
* @throws NoSuchElementException 没有可删除目标
*/
@JvmSynthetic
override suspend fun delete(vararg options: DeleteOption)
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Project https://github.com/simple-robot/simpler-robot
* Email [email protected]
*
* This file is part of the Simple Robot Library.
* This file is part of the Simple Robot Library (Alias: simple-robot, simbot, etc.).
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
Expand All @@ -28,6 +28,7 @@ import love.forte.simbot.ability.DeleteSupport
import love.forte.simbot.ability.SendSupport
import love.forte.simbot.ability.StandardDeleteOption
import love.forte.simbot.common.id.ID
import love.forte.simbot.suspendrunner.ST
import kotlin.jvm.JvmSynthetic


Expand Down Expand Up @@ -114,6 +115,7 @@ public abstract class AggregatedMessageReceipt : StandardMessageReceipt, Iterabl
*
* @see deleteAll
*/
@JvmSynthetic
override suspend fun delete(vararg options: DeleteOption) {
deleteAll(options = options)
}
Expand All @@ -128,6 +130,7 @@ public abstract class AggregatedMessageReceipt : StandardMessageReceipt, Iterabl
*
* @return 删除成功的数量
*/
@ST
public open suspend fun deleteAll(vararg options: DeleteOption): Int {
var count = 0
for (receipt in this) {
Expand Down
2 changes: 1 addition & 1 deletion website

0 comments on commit 1cb5b01

Please sign in to comment.