Class AndInThreads

  • All Implemented Interfaces:
    Scalar<Boolean>

    public final class AndInThreads
    extends Object
    implements Scalar<Boolean>
    Logical conjunction, in multiple threads.

    The usage is same as for And

    This class implements Scalar, which throws a checked Exception. This may not be convenient in many cases. To make it more convenient and get rid of the checked exception you can use the Unchecked decorator. Or you may use IoChecked to wrap it in an IOException.

    There is no thread-safety guarantee.

    Since:
    0.25
    See Also:
    Unchecked, IoChecked
    • Constructor Detail

      • AndInThreads

        @SafeVarargs
        public AndInThreads​(Func<? super X,​Boolean> func,
                            X... src)
        Ctor.
        Type Parameters:
        X - Type of items in the iterable
        Parameters:
        func - Func to map
        src - The iterable
      • AndInThreads

        public AndInThreads​(Func<? super X,​Boolean> func,
                            Iterable<? extends X> src)
        Ctor.
        Type Parameters:
        X - Type of items in the iterable
        Parameters:
        func - Func to map
        src - The iterable
      • AndInThreads

        public AndInThreads​(Iterable<? extends Scalar<Boolean>> src)
        Ctor.
        Parameters:
        src - The iterable
      • AndInThreads

        @SafeVarargs
        public AndInThreads​(ExecutorService svc,
                            Proc<? super X> proc,
                            X... src)
        Ctor.
        Type Parameters:
        X - Type of items in the iterable
        Parameters:
        svc - Executable service to run thread in
        proc - Proc to map
        src - The iterable
      • AndInThreads

        @SafeVarargs
        public AndInThreads​(ExecutorService svc,
                            Func<? super X,​Boolean> func,
                            X... src)
        Ctor.
        Type Parameters:
        X - Type of items in the iterable
        Parameters:
        svc - Executable service to run thread in
        func - Func to map
        src - The iterable
      • AndInThreads

        public AndInThreads​(ExecutorService svc,
                            Proc<? super X> proc,
                            Iterable<? extends X> src)
        Ctor.
        Type Parameters:
        X - Type of items in the iterable
        Parameters:
        svc - Executable service to run thread in
        proc - Proc to use
        src - The iterable
      • AndInThreads

        public AndInThreads​(ExecutorService svc,
                            Func<? super X,​Boolean> func,
                            Iterable<? extends X> src)
        Ctor.
        Type Parameters:
        X - Type of items in the iterable
        Parameters:
        svc - Executable service to run thread in
        func - Func to map
        src - The iterable
      • AndInThreads

        public AndInThreads​(ExecutorService svc,
                            Iterable<? extends Scalar<Boolean>> src)
        Ctor.
        Parameters:
        svc - Executable service to run thread in
        src - The iterable