code: public static boolean isFragment(Bundle bundle) {
          Dictionary<String, String> headers = bundle.getHeaders();
          return headers.get(Constants.FRAGMENT_HOST) != null;
      }
docs: Checks whether or not the given bundle is a fragment
  @param bundle the bundle
  @return {@code true} if the bundle is a fragment, {@code false} otherwise.