code: private static int findTrackIdAtOffset(SlotReference slot, Client client, int offset) throws IOException {
          Message entry = client.renderMenuItems(Message.MenuIdentifier.MAIN_MENU, slot.slot, CdjStatus.TrackType.REKORDBOX, offset, 1).get(0);
          if (entry.getMenuItemType() == Message.MenuItemType.UNKNOWN) {
              logger.warn("Encountered unrecognized track list entry item type: {}", entry);
          }
          return (int)((NumberField)entry.arguments.get(1)).getValue();
      }
docs: As part of checking whether a metadata cache can be auto-mounted for a particular media slot, this method
  looks up the track at the specified offset within the player's track list, and returns its rekordbox ID.
  
  @param slot the slot being considered for auto-attaching a metadata cache
  @param client the connection to the database server on the player holding that slot
  @param offset an index into the list of all tracks present in the slot
  
  @throws IOException if there is a problem communicating with the player