com.skillw.pouvoir.api.feature.operation.OperationElement.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of Pouvoir Show documentation
Show all versions of Pouvoir Show documentation
Bukkit Script Engine Plugin.
package com.skillw.pouvoir.api.feature.operation
/**
* @className OperationElement
*
* @author Glom
* @date 2022/7/19 12:37 Copyright 2022 user.
*/
data class OperationElement(val numberOperation: NumberOperation, val number: Number) {
/**
* 做运算
*
* @param other 其他数字
* @return 运算结果
*/
fun operate(other: Number): Number {
return numberOperation.operate(other, number)
}
override fun toString(): String {
return "Operation { ${numberOperation.key} $number }"
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy