Package org.spongepowered.api.data.value
Interface SetValue<E>
- All Superinterfaces:
- CollectionValue<E,,- Set<E>> - Iterable<E>,- Value<Set<E>>
- All Known Subinterfaces:
- SetValue.Immutable<E>,- SetValue.Mutable<E>
- 
Nested Class SummaryNested ClassesModifier and TypeInterfaceDescriptionstatic interfaceRepresents a type ofCollectionValue.Immutablebacked by aSet.static interfaceRepresents a type ofCollectionValue.Mutablebacked by aSet.Nested classes/interfaces inherited from interface org.spongepowered.api.data.value.ValueValue.Factory
- 
Method SummaryModifier and TypeMethodDescriptionRetrieves an immutable form of this value.Retrieves a mutable form of this value.Retrieves a copy in the mutable form of this value.static <E> SetValue.Immutable<E>immutableOf(Supplier<? extends Key<? extends SetValue<E>>> key, Set<E> element) static <E> SetValue.Immutable<E>immutableOf(Key<? extends SetValue<E>> key, Set<E> element) key()Gets the key for thisValue.static <E> SetValue.Mutable<E>static <E> SetValue.Mutable<E>Methods inherited from interface org.spongepowered.api.data.value.CollectionValueall, contains, containsAll, isEmpty, sizeMethods inherited from interface java.lang.IterableforEach, iterator, spliterator
- 
Method Details- 
mutableOf- Type Parameters:
- E- The element type
- Parameters:
- key- The key
- element- The element
- Returns:
- The constructed mutable value
 
- 
mutableOfstatic <E> SetValue.Mutable<E> mutableOf(Supplier<? extends Key<? extends SetValue<E>>> key, Set<E> element) - Type Parameters:
- E- The element type
- Parameters:
- key- The key
- element- The element
- Returns:
- The constructed mutable value
 
- 
immutableOf- Type Parameters:
- E- The element type
- Parameters:
- key- The key
- element- The element
- Returns:
- The constructed immutable value
 
- 
immutableOfstatic <E> SetValue.Immutable<E> immutableOf(Supplier<? extends Key<? extends SetValue<E>>> key, Set<E> element) - Type Parameters:
- E- The element type
- Parameters:
- key- The key
- element- The element
- Returns:
- The constructed immutable value
 
- 
keyDescription copied from interface:ValueGets the key for thisValue.
- 
asMutableSetValue.Mutable<E> asMutable()Description copied from interface:ValueRetrieves a mutable form of this value. Due to the vague nature of the value itself, some cases can already provide aValue.Mutableinstance where this would simply return itself. In other cases, where the retrieved value is anValue.Immutableinstance, a new mutable value is created with the same key and values.
- 
asMutableCopySetValue.Mutable<E> asMutableCopy()Description copied from interface:ValueRetrieves a copy in the mutable form of this value. The new is created with the same key and values.- Specified by:
- asMutableCopyin interface- CollectionValue<E,- Set<E>> 
- Specified by:
- asMutableCopyin interface- Value<E>
- Returns:
- A mutable value
 
- 
asImmutableSetValue.Immutable<E> asImmutable()Description copied from interface:ValueRetrieves an immutable form of this value. Due to the vague nature of the value itself, some cases can already provide aValue.Immutableinstance where this would simply return itself. In other cases, where the retrieved value is aValue.Mutableinstance, a new immutable value is created with the same key and values.- Specified by:
- asImmutablein interface- CollectionValue<E,- Set<E>> 
- Specified by:
- asImmutablein interface- Value<E>
- Returns:
- An immutable value
 
 
-