@Override public MutableSet<T> tap(Procedure<? super T> procedure) { this.forEach(procedure); return this; }
protected MutableSet<T> getMutableSet() { return (MutableSet<T>) this.getMutableCollection(); }
@Override public boolean equals(Object obj) { return this.getMutableSet().equals(obj); }
@Override public MutableSet<T> asUnmodifiable() { return UnmodifiableMutableSet.of(this); }
/** * This method will take a MutableSet and wrap it directly in a UnmodifiableMutableSet. It will * take any other non-Eclipse-Collections set and first adapt it will a SetAdapter, and then return a * UnmodifiableMutableSet that wraps the adapter. */ public static <E, S extends Set<E>> UnmodifiableMutableSet<E> of(S set) { if (set == null) { throw new IllegalArgumentException("cannot create an UnmodifiableMutableSet for null"); } return new UnmodifiableMutableSet<>(SetAdapter.adapt(set)); }
@Override public MutableSet<T> asUnmodifiable() { return UnmodifiableMutableSet.of(this); }
/** * This method will take a MutableSet and wrap it directly in a UnmodifiableMutableSet. It will * take any other non-Eclipse-Collections set and first adapt it will a SetAdapter, and then return a * UnmodifiableMutableSet that wraps the adapter. */ public static <E, S extends Set<E>> UnmodifiableMutableSet<E> of(S set) { if (set == null) { throw new IllegalArgumentException("cannot create an UnmodifiableMutableSet for null"); } return new UnmodifiableMutableSet<>(SetAdapter.adapt(set)); }
@Override public boolean equals(Object obj) { return this.getMutableSet().equals(obj); }
@Override public MutableSet<T> asUnmodifiable() { return UnmodifiableMutableSet.of(this); }
@Override public MutableSet<T> tap(Procedure<? super T> procedure) { this.forEach(procedure); return this; }
/** * This method will take a MutableSet and wrap it directly in a UnmodifiableMutableSet. It will * take any other non-GS-set and first adapt it will a SetAdapter, and then return a * UnmodifiableMutableSet that wraps the adapter. */ public static <E, S extends Set<E>> UnmodifiableMutableSet<E> of(S set) { if (set == null) { throw new IllegalArgumentException("cannot create an UnmodifiableMutableSet for null"); } return new UnmodifiableMutableSet<>(SetAdapter.adapt(set)); }
protected MutableSet<T> getMutableSet() { return (MutableSet<T>) this.getMutableCollection(); }
@Override public MutableSet<T> newEmpty() { return this.getMutableSet().newEmpty(); }
@Override public MutableSet<T> asUnmodifiable() { return UnmodifiableMutableSet.of(this); }
@Override public MutableSet<T> tap(Procedure<? super T> procedure) { this.forEach(procedure); return this; }
protected MutableSet<T> getMutableSet() { return (MutableSet<T>) this.getMutableCollection(); }
@Override public MutableBooleanSet collectBoolean(BooleanFunction<? super T> booleanFunction) { return this.getMutableSet().collectBoolean(booleanFunction); }
@Override public MutableSet<T> asUnmodifiable() { return UnmodifiableMutableSet.of(this); }
@Override public MutableFloatSet collectFloat(FloatFunction<? super T> floatFunction) { return this.getMutableSet().collectFloat(floatFunction); }
@Override public MutableSet<T> asUnmodifiable() { return UnmodifiableMutableSet.of(this); }