rename[array]: rename primitive array list

This commit is contained in:
godotg
2022-09-25 12:38:15 +08:00
parent d719f328bc
commit af24f802ff
7 changed files with 18 additions and 18 deletions
@@ -752,7 +752,7 @@ public abstract class ByteBufUtils {
public static List<Boolean> readBooleanList(ByteBuf byteBuf) {
var length = readInt(byteBuf);
var list = new FixedSizeListBoolean(CollectionUtils.comfortableCapacity(length));
var list = new ArrayBooleanList(CollectionUtils.comfortableCapacity(length));
for (var i = 0; i < length; i++) {
list.set(i, readBoolean(byteBuf));
}
@@ -830,7 +830,7 @@ public abstract class ByteBufUtils {
public static List<Byte> readByteList(ByteBuf byteBuf) {
var length = readInt(byteBuf);
var list = new FixedSizeListByte(CollectionUtils.comfortableCapacity(length));
var list = new ArrayByteList(CollectionUtils.comfortableCapacity(length));
for (var i = 0; i < length; i++) {
list.set(i, readByte(byteBuf));
}
@@ -916,7 +916,7 @@ public abstract class ByteBufUtils {
public static List<Short> readShortList(ByteBuf byteBuf) {
var length = readInt(byteBuf);
var list = new FixedSizeListShort(CollectionUtils.comfortableCapacity(length));
var list = new ArrayShortList(CollectionUtils.comfortableCapacity(length));
for (var i = 0; i < length; i++) {
list.set(i, readShort(byteBuf));
}
@@ -1074,7 +1074,7 @@ public abstract class ByteBufUtils {
public static List<Long> readLongList(ByteBuf byteBuf) {
var length = readInt(byteBuf);
var list = new FixedSizeListLong(CollectionUtils.comfortableCapacity(length));
var list = new ArrayLongList(CollectionUtils.comfortableCapacity(length));
for (var i = 0; i < length; i++) {
list.set(i, readLong(byteBuf));
}
@@ -1160,7 +1160,7 @@ public abstract class ByteBufUtils {
public static List<Float> readFloatList(ByteBuf byteBuf) {
var length = readInt(byteBuf);
var list = new FixedSizeListFloat(CollectionUtils.comfortableCapacity(length));
var list = new ArrayFloatList(CollectionUtils.comfortableCapacity(length));
for (var i = 0; i < length; i++) {
list.set(i, readFloat(byteBuf));
}
@@ -1246,7 +1246,7 @@ public abstract class ByteBufUtils {
public static List<Double> readDoubleList(ByteBuf byteBuf) {
var length = readInt(byteBuf);
var list = new FixedSizeListDouble(CollectionUtils.comfortableCapacity(length));
var list = new ArrayDoubleList(CollectionUtils.comfortableCapacity(length));
for (var i = 0; i < length; i++) {
list.set(i, readDouble(byteBuf));
}
@@ -21,11 +21,11 @@ import java.util.ListIterator;
* @author godotg
* @version 3.0
*/
public class FixedSizeListBoolean implements List<Boolean> {
public class ArrayBooleanList implements List<Boolean> {
private final boolean[] array;
public FixedSizeListBoolean(int initialCapacity) {
public ArrayBooleanList(int initialCapacity) {
this.array = new boolean[initialCapacity];
}
@@ -21,11 +21,11 @@ import java.util.ListIterator;
* @author godotg
* @version 3.0
*/
public class FixedSizeListByte implements List<Byte> {
public class ArrayByteList implements List<Byte> {
private final byte[] array;
public FixedSizeListByte(int initialCapacity) {
public ArrayByteList(int initialCapacity) {
this.array = new byte[initialCapacity];
}
@@ -21,11 +21,11 @@ import java.util.ListIterator;
* @author godotg
* @version 3.0
*/
public class FixedSizeListDouble implements List<Double> {
public class ArrayDoubleList implements List<Double> {
private final double[] array;
public FixedSizeListDouble(int initialCapacity) {
public ArrayDoubleList(int initialCapacity) {
this.array = new double[initialCapacity];
}
@@ -21,11 +21,11 @@ import java.util.ListIterator;
* @author godotg
* @version 3.0
*/
public class FixedSizeListFloat implements List<Float> {
public class ArrayFloatList implements List<Float> {
private final float[] array;
public FixedSizeListFloat(int initialCapacity) {
public ArrayFloatList(int initialCapacity) {
this.array = new float[initialCapacity];
}
@@ -21,11 +21,11 @@ import java.util.ListIterator;
* @author godotg
* @version 3.0
*/
public class FixedSizeListLong implements List<Long> {
public class ArrayLongList implements List<Long> {
private final long[] array;
public FixedSizeListLong(int initialCapacity) {
public ArrayLongList(int initialCapacity) {
this.array = new long[initialCapacity];
}
@@ -21,11 +21,11 @@ import java.util.ListIterator;
* @author godotg
* @version 3.0
*/
public class FixedSizeListShort implements List<Short> {
public class ArrayShortList implements List<Short> {
private final short[] array;
public FixedSizeListShort(int initialCapacity) {
public ArrayShortList(int initialCapacity) {
this.array = new short[initialCapacity];
}