|
|
@@ -1,8 +1,5 @@
|
|
|
package net.ranides.assira.collection.arrays;
|
|
|
|
|
|
-import net.ranides.assira.collection.lists.ListBuilder;
|
|
|
-
|
|
|
-import javax.jws.Oneway;
|
|
|
import java.util.Collection;
|
|
|
import java.util.Comparator;
|
|
|
import java.util.function.IntFunction;
|
|
|
@@ -13,7 +10,7 @@ public class NativeArrayBuilder {
|
|
|
|
|
|
private int count;
|
|
|
private NativeArray array;
|
|
|
- private Comparator cmp;
|
|
|
+ private Comparator<Object> cmp;
|
|
|
|
|
|
public NativeArrayBuilder(Class<?> component) {
|
|
|
this(component, 8);
|
|
|
@@ -141,11 +138,12 @@ public class NativeArrayBuilder {
|
|
|
return this;
|
|
|
}
|
|
|
|
|
|
+ @SuppressWarnings({"unchecked", "rawtypes"})
|
|
|
public NativeArrayBuilder sorted(Comparator<?> cmp) {
|
|
|
if(this.cmp != null) {
|
|
|
- this.cmp = this.cmp.thenComparing(cmp);
|
|
|
+ this.cmp = this.cmp.thenComparing((Comparator)cmp);
|
|
|
} else {
|
|
|
- this.cmp = cmp;
|
|
|
+ this.cmp = (Comparator)cmp;
|
|
|
}
|
|
|
return this;
|
|
|
}
|