mirror of
https://github.com/mamoe/mirai.git
synced 2025-01-11 02:50:15 +08:00
Add resolve context for PluginDependency.versionRequirement
This commit is contained in:
parent
b2ad961e8d
commit
e60bba3e08
@ -16,6 +16,7 @@ import kotlinx.serialization.Serializable
|
|||||||
import kotlinx.serialization.builtins.serializer
|
import kotlinx.serialization.builtins.serializer
|
||||||
import net.mamoe.mirai.console.compiler.common.ResolveContext
|
import net.mamoe.mirai.console.compiler.common.ResolveContext
|
||||||
import net.mamoe.mirai.console.compiler.common.ResolveContext.Kind.PLUGIN_ID
|
import net.mamoe.mirai.console.compiler.common.ResolveContext.Kind.PLUGIN_ID
|
||||||
|
import net.mamoe.mirai.console.compiler.common.ResolveContext.Kind.VERSION_REQUIREMENT
|
||||||
import net.mamoe.mirai.console.internal.data.map
|
import net.mamoe.mirai.console.internal.data.map
|
||||||
import net.mamoe.mirai.console.util.SemVersion
|
import net.mamoe.mirai.console.util.SemVersion
|
||||||
|
|
||||||
@ -37,7 +38,7 @@ public data class PluginDependency @JvmOverloads constructor(
|
|||||||
*
|
*
|
||||||
* @see SemVersion.Requirement
|
* @see SemVersion.Requirement
|
||||||
*/
|
*/
|
||||||
public val versionRequirement: String? = null,
|
@ResolveContext(VERSION_REQUIREMENT) public val versionRequirement: String? = null,
|
||||||
/**
|
/**
|
||||||
* 若为 `false`, 插件在找不到此依赖时也能正常加载.
|
* 若为 `false`, 插件在找不到此依赖时也能正常加载.
|
||||||
*/
|
*/
|
||||||
|
Loading…
Reference in New Issue
Block a user