Class CompositeDevice

java.lang.Object
com.yubico.yubikit.desktop.CompositeDevice
All Implemented Interfaces:
com.yubico.yubikit.core.YubiKeyDevice, Closeable, AutoCloseable

public class CompositeDevice extends Object implements com.yubico.yubikit.core.YubiKeyDevice, Closeable
  • Method Details

    • getFingerprint

      public String getFingerprint()
      Returns a fingerprint for this composite device derived from the underlying resolved UsbYubiKeyDevice instances.

      The fingerprint is obtained from the first resolved underlying device node. It is not guaranteed to be stable across unplug/replug cycles or process restarts.

      Returns:
      the device fingerprint, or the internal key if no resolved device is available
    • getTransport

      public com.yubico.yubikit.core.Transport getTransport()
      Specified by:
      getTransport in interface com.yubico.yubikit.core.YubiKeyDevice
    • supportsConnection

      public boolean supportsConnection(Class<? extends com.yubico.yubikit.core.YubiKeyConnection> connectionType)
      Specified by:
      supportsConnection in interface com.yubico.yubikit.core.YubiKeyDevice
    • requestConnection

      public <T extends com.yubico.yubikit.core.YubiKeyConnection> void requestConnection(Class<T> connectionType, com.yubico.yubikit.core.util.Callback<com.yubico.yubikit.core.util.Result<T,IOException>> callback)
      Specified by:
      requestConnection in interface com.yubico.yubikit.core.YubiKeyDevice
    • openConnection

      public <T extends com.yubico.yubikit.core.YubiKeyConnection> T openConnection(Class<T> connectionType) throws IOException
      Specified by:
      openConnection in interface com.yubico.yubikit.core.YubiKeyDevice
      Throws:
      IOException
    • getPidGroup

      public UsbPidGroup getPidGroup()
    • close

      public void close() throws IOException
      Specified by:
      close in interface AutoCloseable
      Specified by:
      close in interface Closeable
      Throws:
      IOException