com.notnoop.mpns.internal
Class Utilities

java.lang.Object
  extended by com.notnoop.mpns.internal.Utilities

public final class Utilities
extends Object


Field Summary
static String XML_CONTENT_TYPE
          The content type "text/xml"
 
Method Summary
static String escapeXml(String value)
           
static void fireDelegate(MpnsNotification message, org.apache.http.HttpResponse response, MpnsDelegate delegate, String subscriptionUri)
           
static int getTileDelivery(DeliveryClass delivery)
           
static String ifNonNull(Object cond, String value)
          Returns is the cond is non-null; otherwise returns an empty String.
static MpnsResponse logicalResponseFor(org.apache.http.HttpResponse response)
           
static org.apache.http.impl.conn.tsccm.ThreadSafeClientConnManager poolManager(int maxConnections)
           
static byte[] toUTF8(String content)
           
static String xmlElement(String name, String content)
           
static String xmlElementClear(String name, String content)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

XML_CONTENT_TYPE

public static String XML_CONTENT_TYPE
The content type "text/xml"

Method Detail

poolManager

public static org.apache.http.impl.conn.tsccm.ThreadSafeClientConnManager poolManager(int maxConnections)

ifNonNull

public static String ifNonNull(Object cond,
                               String value)
Returns is the cond is non-null; otherwise returns an empty String.


xmlElement

public static String xmlElement(String name,
                                String content)

xmlElementClear

public static String xmlElementClear(String name,
                                     String content)

escapeXml

public static String escapeXml(String value)

toUTF8

public static byte[] toUTF8(String content)

logicalResponseFor

public static MpnsResponse logicalResponseFor(org.apache.http.HttpResponse response)

fireDelegate

public static void fireDelegate(MpnsNotification message,
                                org.apache.http.HttpResponse response,
                                MpnsDelegate delegate,
                                String subscriptionUri)

getTileDelivery

public static int getTileDelivery(DeliveryClass delivery)


Copyright © 2015. All Rights Reserved.