Package com.griefdefender.api.data
Interface EconomyDataGetter
- All Known Subinterfaces:
EconomyData
public interface EconomyDataGetter
-
Method Summary
Modifier and TypeMethodDescriptionGets a list ofUUID's of delinquent users who still owe a balance for past rentals.Gets thePaymentTransaction's.Gets thePaymentType.doublegetRentBalance(UUID uuid) Gets the current owed rent balance.Gets a mutable map of user rent balances.booleanGets rental break ability.@Nullable InstantGets the rent end date.Gets a list ofUUID's of users currently renting claim.intGets the maximum rent time.intGets the minimum rent time.@Nullable InstantGets the rent past due date.@Nullable InstantGets the next rent payment due date.doubleGets the rent rate ofClaim.@Nullable com.flowpowered.math.vector.Vector3iGets the rent sign location.@Nullable InstantGets the rent start date.booleanGets whether a rented claim will strip its NBT data on restore.@Nullable InstantGets the sale end date of claim.doubleGets the sale price ofClaim.@Nullable com.flowpowered.math.vector.Vector3iGets the sale sign location.doubleGets the current owed tax balance.@Nullable InstantGets the tax past due date.booleanGets whether claim is for rent.booleanGets whether claim is for sale.default booleanisRented()Gets whether claim is currently being rented.default booleanisUserRenting(User user) Checks ifUseris renting.booleanisUserRenting(UUID uuid) Checks ifUseris renting.
-
Method Details
-
getRentSignPosition
@Nullable com.flowpowered.math.vector.Vector3i getRentSignPosition()Gets the rent sign location.- Returns:
- The rent sign position, if available
-
getSaleSignPosition
@Nullable com.flowpowered.math.vector.Vector3i getSaleSignPosition()Gets the sale sign location.- Returns:
- The sale sign position, if available
-
getPaymentTransactions
Gets thePaymentTransaction's.- Parameters:
type- The payment transaction type- Returns:
- The list of payment transactions
-
getRenters
Gets a list ofUUID's of users currently renting claim.- Returns:
- The list of uuid's renting claim
-
getDelinquentRenters
Gets a list ofUUID's of delinquent users who still owe a balance for past rentals.- Returns:
- The list of delinquent uuid's who owe balance
-
isUserRenting
Checks ifUseris renting.- Parameters:
user- The user- Returns:
- true if renting, false if not
-
isUserRenting
Checks ifUseris renting.- Parameters:
uuid- The uuid- Returns:
- true if renting, false if not
-
getRentPastDueDate
@Nullable Instant getRentPastDueDate()Gets the rent past due date. Note: This will only return a date if the current renter has missed a payment.- Returns:
- The rent past due date, if available
-
getTaxPastDueDate
@Nullable Instant getTaxPastDueDate()Gets the tax past due date. Note: This will only return a date if the current tax payer has missed a payment.- Returns:
- The tax past due date, if available
-
getPaymentType
PaymentType getPaymentType()Gets thePaymentType.- Returns:
- The payment type
-
isForSale
boolean isForSale()Gets whether claim is for sale.- Returns:
- whether claim is for sale
-
isForRent
boolean isForRent()Gets whether claim is for rent.- Returns:
- whether claim is for rent
-
getRentBreakAbility
boolean getRentBreakAbility()Gets rental break ability.- Returns:
- Whether renters or rental trusted have ability to break owner blocks.
-
isRented
default boolean isRented()Gets whether claim is currently being rented.- Returns:
- whether claim is rented
-
getRentRate
double getRentRate()Gets the rent rate ofClaim.- Returns:
- The rent rate, or -1 if not set.
-
getRentMinTime
int getRentMinTime()Gets the minimum rent time.- Returns:
- The minimum rent time
-
getRentMaxTime
int getRentMaxTime()Gets the maximum rent time.- Returns:
- The maximum rent time
-
getRentStripNbt
boolean getRentStripNbt()Gets whether a rented claim will strip its NBT data on restore. Note: This is only used when a rented claim is restored on rental end.- Returns:
- Whether NBT will be stripped on restore
-
getRentStartDate
@Nullable Instant getRentStartDate()Gets the rent start date.- Returns:
- The rent start date, if available
-
getRentEndDate
@Nullable Instant getRentEndDate()Gets the rent end date. Note: If not set, the claim may be rented as long as needed.- Returns:
- The rent end date, if available
-
getRentPaymentDueDate
@Nullable Instant getRentPaymentDueDate()Gets the next rent payment due date.- Returns:
- The rent payment due date
-
getSaleEndDate
@Nullable Instant getSaleEndDate()Gets the sale end date of claim.- Returns:
- The sale end date, if available
-
getSalePrice
double getSalePrice()Gets the sale price ofClaim.- Returns:
- The sale price, or -1 if not set.
-
getRentBalance
Gets the current owed rent balance.- Returns:
- The rent balance
-
getTaxBalance
double getTaxBalance()Gets the current owed tax balance.- Returns:
- The tax balance
-
getRentBalances
Gets a mutable map of user rent balances.- Returns:
- The mutable map of user rent balances
-