code: public static byte[] toByteArray(File file) {
          FileInputStream is = null;
          try {
              is = new FileInputStream(file);
              return toByteArray(is);
          } catch (IOException e) {
              throw new RuntimeException(e);
          } finally {
              closeQuietly(is);
          }
      }
docs: <p>toByteArray.</p>
  
  @param file a {@link java.io.File} object.
  @return an array of byte.