Interface USBDevicePredicate

All Known Implementing Classes:
USBDeviceFilter
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface USBDevicePredicate
Represents a predicate (boolean-valued function) of one argument, evaluated for a given USB device.

This is a functional interface whose functional method is matches(USBDevice).

  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Evaluates this predicate on the given USB device.
    static boolean
    Test if the USB devices matches any of the filter conditions.
  • Method Details

    • matches

      boolean matches(USBDevice device)
      Evaluates this predicate on the given USB device.
      Parameters:
      device - the USB device
      Returns:
      true of the devices matches the predicate, otherwise false
    • matchesAny

      static boolean matchesAny(USBDevice device, List<USBDevicePredicate> predicates)
      Test if the USB devices matches any of the filter conditions.
      Parameters:
      device - the USB device
      predicates - a list of filter predicates
      Returns:
      true if it matches, false otherwise