This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * This utility class provides an abstraction layer for sending multipart HTTP | |
| * POST requests to a web server. | |
| * @author www.codejava.net | |
| * | |
| */ | |
| public class MultipartUtility { | |
| private final String boundary; | |
| private static final String LINE_FEED = "\r\n"; | |
| private HttpURLConnection httpConn; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (ns util | |
| (:use clojure.contrib.generic.math-functions)) | |
| ; http://en.wikipedia.org/wiki/Earth_radius | |
| (def R 6367) | |
| ; rad argument to haversine function (180° d/πR). | |
| (defn rad [x] | |
| (* x (/ Math/PI 180))) |
NewerOlder