mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2024-11-21 20:56:45 +01:00
Checkstyle
This commit is contained in:
parent
0484915233
commit
e06bf2cd6b
@ -136,7 +136,9 @@ public class SimpleBackupManager implements BackupManager {
|
|||||||
return this.backupLimit;
|
return this.backupLimit;
|
||||||
}
|
}
|
||||||
|
|
||||||
private record PlotCacheKey(Plot plot) {
|
private record PlotCacheKey(
|
||||||
|
Plot plot
|
||||||
|
) {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean equals(final Object o) {
|
public boolean equals(final Object o) {
|
||||||
|
@ -35,8 +35,15 @@ import java.util.Map;
|
|||||||
* the component GUI
|
* the component GUI
|
||||||
*/
|
*/
|
||||||
@SerializableAs("preset")
|
@SerializableAs("preset")
|
||||||
public record ComponentPreset(ClassicPlotManagerComponent component, String pattern, double cost, String permission,
|
public record ComponentPreset(
|
||||||
String displayName, List<String> description, ItemType icon) implements ConfigurationSerializable {
|
ClassicPlotManagerComponent component,
|
||||||
|
String pattern,
|
||||||
|
double cost,
|
||||||
|
String permission,
|
||||||
|
String displayName,
|
||||||
|
List<String> description,
|
||||||
|
ItemType icon
|
||||||
|
) implements ConfigurationSerializable {
|
||||||
|
|
||||||
@SuppressWarnings("unchecked")
|
@SuppressWarnings("unchecked")
|
||||||
public static ComponentPreset deserialize(final @NonNull Map<String, Object> map) {
|
public static ComponentPreset deserialize(final @NonNull Map<String, Object> map) {
|
||||||
|
@ -3414,7 +3414,10 @@ public class SQLManager implements AbstractDB {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private record LegacySettings(int id, PlotSettings settings) {
|
private record LegacySettings(
|
||||||
|
int id,
|
||||||
|
PlotSettings settings
|
||||||
|
) {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -21,7 +21,11 @@ package com.plotsquared.core.location;
|
|||||||
import com.plotsquared.core.util.MathMan;
|
import com.plotsquared.core.util.MathMan;
|
||||||
import com.plotsquared.core.util.StringMan;
|
import com.plotsquared.core.util.StringMan;
|
||||||
|
|
||||||
public record ChunkWrapper(String world, int x, int z) {
|
public record ChunkWrapper(
|
||||||
|
String world,
|
||||||
|
int x,
|
||||||
|
int z
|
||||||
|
) {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int hashCode() {
|
public int hashCode() {
|
||||||
|
@ -215,7 +215,11 @@ public final class BlockBucket implements ConfigurationSerializable {
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
private record Range(int min, int max, boolean automatic) {
|
private record Range(
|
||||||
|
int min,
|
||||||
|
int max,
|
||||||
|
boolean automatic
|
||||||
|
) {
|
||||||
|
|
||||||
public int getWeight() {
|
public int getWeight() {
|
||||||
return max - min;
|
return max - min;
|
||||||
|
@ -20,6 +20,13 @@ package com.plotsquared.core.plot.comment;
|
|||||||
|
|
||||||
import com.plotsquared.core.plot.PlotId;
|
import com.plotsquared.core.plot.PlotId;
|
||||||
|
|
||||||
public record PlotComment(String world, PlotId id, String comment, String senderName, String inbox, long timestamp) {
|
public record PlotComment(
|
||||||
|
String world,
|
||||||
|
PlotId id,
|
||||||
|
String comment,
|
||||||
|
String senderName,
|
||||||
|
String inbox,
|
||||||
|
long timestamp
|
||||||
|
) {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -76,7 +76,10 @@ public abstract class TimedFlag<T, F extends PlotFlag<TimedFlag.Timed<T>, F>>
|
|||||||
return getValue().toString();
|
return getValue().toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
public record Timed<T>(int interval, T value) {
|
public record Timed<T>(
|
||||||
|
int interval,
|
||||||
|
T value
|
||||||
|
) {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
|
@ -24,7 +24,13 @@ import com.plotsquared.core.plot.PlotId;
|
|||||||
import org.checkerframework.checker.nullness.qual.NonNull;
|
import org.checkerframework.checker.nullness.qual.NonNull;
|
||||||
import org.checkerframework.checker.nullness.qual.Nullable;
|
import org.checkerframework.checker.nullness.qual.Nullable;
|
||||||
|
|
||||||
public record AutoQuery(PlotPlayer<?> player, PlotId startId, int sizeX, int sizeZ, PlotArea plotArea) {
|
public record AutoQuery(
|
||||||
|
PlotPlayer<?> player,
|
||||||
|
PlotId startId,
|
||||||
|
int sizeX,
|
||||||
|
int sizeZ,
|
||||||
|
PlotArea plotArea
|
||||||
|
) {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Crate a new auto query
|
* Crate a new auto query
|
||||||
|
@ -23,7 +23,10 @@ import com.plotsquared.core.configuration.ConfigurationNode;
|
|||||||
/**
|
/**
|
||||||
* This class wraps an array of {@link ConfigurationNode}s.
|
* This class wraps an array of {@link ConfigurationNode}s.
|
||||||
*/
|
*/
|
||||||
public record SettingsNodesWrapper(ConfigurationNode[] settingsNodes, SetupStep afterwards) {
|
public record SettingsNodesWrapper(
|
||||||
|
ConfigurationNode[] settingsNodes,
|
||||||
|
SetupStep afterwards
|
||||||
|
) {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the first step of this wrapper or the step or the
|
* Returns the first step of this wrapper or the step or the
|
||||||
|
@ -18,6 +18,9 @@
|
|||||||
*/
|
*/
|
||||||
package com.plotsquared.core.util;
|
package com.plotsquared.core.util;
|
||||||
|
|
||||||
public record FileBytes(String path, byte[] data) {
|
public record FileBytes(
|
||||||
|
String path,
|
||||||
|
byte[] data
|
||||||
|
) {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -300,7 +300,9 @@ public final class PlaceholderRegistry {
|
|||||||
/**
|
/**
|
||||||
* Event called when a new {@link Placeholder} has been added
|
* Event called when a new {@link Placeholder} has been added
|
||||||
*/
|
*/
|
||||||
public record PlaceholderAddedEvent(Placeholder placeholder) {
|
public record PlaceholderAddedEvent(
|
||||||
|
Placeholder placeholder
|
||||||
|
) {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -25,7 +25,10 @@ import java.util.UUID;
|
|||||||
/**
|
/**
|
||||||
* A pair consisting of a UUID and a username
|
* A pair consisting of a UUID and a username
|
||||||
*/
|
*/
|
||||||
public record UUIDMapping(@NonNull UUID uuid, @NonNull String username) {
|
public record UUIDMapping(
|
||||||
|
@NonNull UUID uuid,
|
||||||
|
@NonNull String username
|
||||||
|
) {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean equals(final Object o) {
|
public boolean equals(final Object o) {
|
||||||
|
Loading…
Reference in New Issue
Block a user