mirror of
				https://github.com/SquidDev-CC/CC-Tweaked
				synced 2025-10-31 13:42:59 +00:00 
			
		
		
		
	Remove superflous Nonnull/Notnull annotations
This commit is contained in:
		| @@ -18,7 +18,6 @@ import net.minecraft.commands.CommandBuildContext; | ||||
| import net.minecraft.commands.CommandSourceStack; | ||||
| import net.minecraft.commands.synchronization.ArgumentTypeInfo; | ||||
| import net.minecraft.network.FriendlyByteBuf; | ||||
| import org.jetbrains.annotations.NotNull; | ||||
| 
 | ||||
| import java.util.*; | ||||
| import java.util.concurrent.CompletableFuture; | ||||
| @@ -159,14 +158,14 @@ public final class ComputersArgumentType implements ArgumentType<ComputersArgume | ||||
|         } | ||||
| 
 | ||||
|         @Override | ||||
|         public ComputersArgumentType.Template unpack(@NotNull ComputersArgumentType argumentType) { | ||||
|         public ComputersArgumentType.Template unpack(ComputersArgumentType argumentType) { | ||||
|             return new ComputersArgumentType.Template(this, argumentType.requireSome); | ||||
|         } | ||||
|     } | ||||
| 
 | ||||
|     public record Template(Info info, boolean requireSome) implements ArgumentTypeInfo.Template<ComputersArgumentType> { | ||||
|         @Override | ||||
|         public ComputersArgumentType instantiate(@NotNull CommandBuildContext context) { | ||||
|         public ComputersArgumentType instantiate(CommandBuildContext context) { | ||||
|             return requireSome ? SOME : MANY; | ||||
|         } | ||||
| 
 | ||||
|   | ||||
| @@ -17,7 +17,6 @@ import net.minecraft.commands.synchronization.ArgumentTypeInfo; | ||||
| import net.minecraft.commands.synchronization.ArgumentTypeInfos; | ||||
| import net.minecraft.network.FriendlyByteBuf; | ||||
| import net.minecraft.network.chat.Component; | ||||
| import org.jetbrains.annotations.NotNull; | ||||
| 
 | ||||
| import java.util.ArrayList; | ||||
| import java.util.Collection; | ||||
| @@ -144,7 +143,7 @@ public final class RepeatArgumentType<T, U> implements ArgumentType<List<T>> { | ||||
|     ) implements ArgumentTypeInfo.Template<RepeatArgumentType<?, ?>> { | ||||
|         @Override | ||||
|         @SuppressWarnings({ "unchecked", "rawtypes" }) | ||||
|         public RepeatArgumentType<?, ?> instantiate(@NotNull CommandBuildContext commandBuildContext) { | ||||
|         public RepeatArgumentType<?, ?> instantiate(CommandBuildContext commandBuildContext) { | ||||
|             var child = child().instantiate(commandBuildContext); | ||||
|             return flatten ? RepeatArgumentType.someFlat((ArgumentType) child, some()) : RepeatArgumentType.some(child, some()); | ||||
|         } | ||||
|   | ||||
| @@ -27,7 +27,6 @@ import io.netty.handler.ssl.SslHandler; | ||||
| import io.netty.handler.timeout.ReadTimeoutException; | ||||
| import io.netty.handler.traffic.AbstractTrafficShapingHandler; | ||||
| import io.netty.handler.traffic.GlobalTrafficShapingHandler; | ||||
| import org.jetbrains.annotations.NotNull; | ||||
| import org.slf4j.Logger; | ||||
| import org.slf4j.LoggerFactory; | ||||
| 
 | ||||
| @@ -193,7 +192,7 @@ public final class NetworkUtils { | ||||
|      * @return The SSL handler. | ||||
|      * @see io.netty.handler.ssl.SslHandler | ||||
|      */ | ||||
|     private static SslHandler makeSslHandler(SocketChannel ch, @NotNull SslContext sslContext, int timeout, String peerHost, int peerPort) { | ||||
|     private static SslHandler makeSslHandler(SocketChannel ch, SslContext sslContext, int timeout, String peerHost, int peerPort) { | ||||
|         var handler = sslContext.newHandler(ch.alloc(), peerHost, peerPort); | ||||
|         if (timeout > 0) handler.setHandshakeTimeoutMillis(timeout); | ||||
|         return handler; | ||||
|   | ||||
| @@ -72,7 +72,6 @@ import net.minecraft.world.phys.BlockHitResult; | ||||
| import net.minecraft.world.phys.EntityHitResult; | ||||
| import net.minecraft.world.phys.Vec3; | ||||
| 
 | ||||
| import javax.annotation.Nonnull; | ||||
| import javax.annotation.Nullable; | ||||
| import java.util.ArrayList; | ||||
| import java.util.Collection; | ||||
| @@ -350,7 +349,6 @@ public class PlatformHelperImpl implements PlatformHelper { | ||||
|             return object; | ||||
|         } | ||||
| 
 | ||||
|         @Nonnull | ||||
|         @Override | ||||
|         public Iterator<T> iterator() { | ||||
|             return registry.iterator(); | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Jonathan Coates
					Jonathan Coates