Annotate Nullable

This commit is contained in:
Andrea Cavalli 2021-09-22 18:26:29 +02:00
parent fcad378288
commit ff703453f8

View File

@ -4,10 +4,11 @@ import java.io.DataInput;
import java.io.DataOutput;
import java.io.IOException;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
public interface DataSerializer<T> {
void serialize(DataOutput dataOutput, @NotNull T data) throws IOException;
void serialize(DataOutput dataOutput, @Nullable T data) throws IOException;
@NotNull T deserialize(DataInput dataInput) throws IOException;
}