@Immutable public static final class u.OptionalByte extends Object implements Comparable<u.OptionalByte>, Immutable
public static u.OptionalByte empty()
public static u.OptionalByte of(byte value)
value - public static u.OptionalByte ofNullable(Byte val)
val - public byte get()
throws NoSuchElementException
NoSuchElementException - the no such element exceptionpublic boolean isPresent()
public boolean isEmpty()
public <E extends Exception> u.OptionalByte ifPresent(Throwables.ByteConsumer<E> action) throws E extends Exception
E - action - E - the eE extends Exceptionpublic <E extends Exception,E2 extends Exception> u.OptionalByte ifPresentOrElse(Throwables.ByteConsumer<E> action, Throwables.Runnable<E2> emptyAction) throws E extends Exception, E2 extends Exception
E - E2 - action - emptyAction - E - the eE2 - the e2E extends Exceptionpublic <E extends Exception> u.OptionalByte filter(Throwables.BytePredicate<E> predicate) throws E extends Exception
E - predicate - E - the eE extends Exceptionpublic <E extends Exception> u.OptionalByte map(Throwables.ByteUnaryOperator<E> mapper) throws E extends Exception
E - mapper - E - the eE extends Exceptionpublic <E extends Exception> u.OptionalInt mapToInt(Throwables.ToIntFunction<Byte,E> mapper) throws E extends Exception
E - mapper - E - the eE extends Exceptionpublic <T,E extends Exception> u.Nullable<T> mapToObj(Throwables.ByteFunction<T,E> mapper) throws E extends Exception
T - E - mapper - E - the eE extends Exceptionpublic <T,E extends Exception> u.Optional<T> mapToNonNull(Throwables.ByteFunction<T,E> mapper) throws E extends Exception
E extends Exceptionpublic <E extends Exception> u.OptionalByte flatMap(Throwables.ByteFunction<u.OptionalByte,E> mapper) throws E extends Exception
E - mapper - E - the eE extends Exceptionpublic <E extends Exception> u.OptionalByte or(Throwables.Supplier<u.OptionalByte,E> supplier) throws E extends Exception
E - supplier - E - the eE extends Exceptionpublic byte orZero()
public byte orElseThrow()
throws NoSuchElementException
NoSuchElementException - the no such element exceptionpublic byte orElse(byte other)
other - public <E extends Exception> byte orElseGet(Throwables.ByteSupplier<E> other) throws E extends Exception
E - other - E - the eE extends Exceptionpublic <X extends Throwable> byte orElseThrow(Supplier<? extends X> exceptionSupplier) throws X extends Throwable
X - exceptionSupplier - X - the xX extends Throwablepublic ImmutableList<Byte> toImmutableList()
public ImmutableSet<Byte> toImmutableSet()
public u.Optional<Byte> boxed()
public int compareTo(u.OptionalByte optional)
compareTo in interface Comparable<u.OptionalByte>optional - public boolean equals(Object obj)
Copyright © 2021. All rights reserved.