public class EconomyResponse
extends java.lang.Object
EconomyResponse.ResponseType indicating whether the plugin currently being used for Economy actually allows
the method, or if the operation was a success or failure.
一个表示经济方法的典型回报.
它包含了EconomyResponse.ResponseType来表示当前经济插件是否支持, 或者操作是否成功.| Modifier and Type | Class and Description |
|---|---|
static class |
EconomyResponse.ResponseType
Enum for types of Responses indicating the status of a method call.
|
| Modifier and Type | Field and Description |
|---|---|
double |
amount
Amount modified by calling method
调用方法传递的金额
|
double |
balance
New balance of account
新的账户余额
|
java.lang.String |
errorMessage
Error message if the variable 'type' is ResponseType.FAILURE
如果变量的"类型"为
ResponseType.FAILURE的错误信息 |
EconomyResponse.ResponseType |
type
Success or failure of call.
|
| Constructor and Description |
|---|
EconomyResponse(double amount,
double balance,
EconomyResponse.ResponseType type,
java.lang.String errorMessage)
Constructor for EconomyResponse
EconomyRespone的构造函数 |
| Modifier and Type | Method and Description |
|---|---|
boolean |
transactionSuccess()
Checks if an operation was successful
检查操作是否成功
|
public final double amount
public final double balance
public final EconomyResponse.ResponseType type
EconomyResponse.ResponseType来表示错误的结果public final java.lang.String errorMessage
ResponseType.FAILURE的错误信息public EconomyResponse(double amount,
double balance,
EconomyResponse.ResponseType type,
java.lang.String errorMessage)
EconomyRespone的构造函数amount - Amount modified during operation
操作中修改的金额balance - New balance of account
新的账户余额type - Success or failure type of the operation
操作成功或者失败errorMessage - Error message if necessary (commonly null)
错误信息(如果有必要)(一般为null)