public static @Nullable DataProvider getDataProviderEx(@Nullable Object component) {
    DataProvider dataProvider = null;
    if (component instanceof DataProvider) {
      dataProvider = (DataProvider)component;
    }
    else if (component instanceof JComponent) {
      dataProvider = getDataProvider((JComponent)component);
    }

    if (dataProvider instanceof BackgroundableDataProvider) {
      dataProvider = ((BackgroundableDataProvider)dataProvider).createBackgroundDataProvider();
    }

    return dataProvider;
  }
public static @Nullable DataProvider getDataProviderEx(@Nullable Object component)