Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

clean up Utilities, by removing extra methods

  • Loading branch information...
commit 80cbbc67fafe586674d5629eeb4e508df6e9464a 1 parent f8ba2f4
@notnoop authored
Showing with 0 additions and 24 deletions.
  1. +0 −24 src/main/java/com/notnoop/mpns/internal/Utilities.java
View
24 src/main/java/com/notnoop/mpns/internal/Utilities.java
@@ -51,26 +51,6 @@
*/
public static String XML_CONTENT_TYPE = "text/xml";
- public static String readFully(InputStream is) {
- final char[] buffer = new char[0x10000];
- StringBuilder out = new StringBuilder();
- try {
- Reader in = new InputStreamReader(is, "UTF-8");
- int read;
- do {
- read = in.read(buffer, 0, buffer.length);
- if (read>0) {
- out.append(buffer, 0, read);
- }
- } while (read>=0);
- return out.toString();
- } catch (RuntimeException e) {
- throw e;
- } catch (Exception e) {
- throw new RuntimeException(e);
- }
- }
-
public static ThreadSafeClientConnManager poolManager(int maxConnections) {
ThreadSafeClientConnManager cm = new ThreadSafeClientConnManager();
cm.setMaxTotal(maxConnections);
@@ -152,10 +132,6 @@ public static MpnsResponse logicalResponseFor(HttpResponse response) {
return null;
}
- public static String messageIdOf(HttpResponse response) {
- return headerValue(response, "X-MessageID");
- }
-
public static void fireDelegate(MpnsNotification message, HttpResponse response, MpnsDelegate delegate) {
if (delegate != null) {
MpnsResponse r = Utilities.logicalResponseFor(response);
Please sign in to comment.
Something went wrong with that request. Please try again.