public static boolean isMimeTypeImage(String mimeType){
  return mimeType != null && mimeType.startsWith("image/");
}

public static boolean isMimeTypeImage ( String mimeType ) { return mimeType != null && mimeType . startsWith ( "image/" ) ; }
checks whether the mime type represents an image media item .
