|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.relayrides.pushy.apns.ApnsEnvironment
public class ApnsEnvironment
An APNs environment is a set of servers that provide push notification services. Apple provides two environments: one production environment and one "sandbox" environment. Custom environments may be created for development and testing purposes.
APNs environments may optionally require TLS. Both Apple-provided environments require TLS. See "Provisioning and Development" for details.
Constructor Summary | |
---|---|
ApnsEnvironment(String apnsGatewayHost,
int apnsGatewayPort,
String feedbackHost,
int feedbackPort,
boolean tlsRequired)
Constructs a new APenvironment with the given host names and ports. |
Method Summary | |
---|---|
String |
getApnsGatewayHost()
Returns the host name of the APNs gateway in this environment. |
int |
getApnsGatewayPort()
Returns the TCP port for the APNs gateway in this environment. |
String |
getFeedbackHost()
Returns the host name of the APNs feedback service in this environment. |
int |
getFeedbackPort()
Returns the TCP port for the APNs feedback service in this environment. |
static ApnsEnvironment |
getProductionEnvironment()
Returns an APNs environment for connecting to Apple's production servers. |
static ApnsEnvironment |
getSandboxEnvironment()
Returns an APNs environment for connecting to Apple's sandbox servers. |
boolean |
isTlsRequired()
Indicates whether this environment requires TLS. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ApnsEnvironment(String apnsGatewayHost, int apnsGatewayPort, String feedbackHost, int feedbackPort, boolean tlsRequired)
apnsGatewayHost
- the host name of the APNs gatewayapnsGatewayPort
- the TCP port for the APNs gatewayfeedbackHost
- the host name of the APNs feedback servicefeedbackPort
- the TCP port for the APNs feedback servicetlsRequired
- true
if this environment requires TLS or false
otherwiseMethod Detail |
---|
public String getApnsGatewayHost()
public int getApnsGatewayPort()
public String getFeedbackHost()
public int getFeedbackPort()
public boolean isTlsRequired()
true
if this environment requires TLS or false
otherwisepublic static ApnsEnvironment getProductionEnvironment()
public static ApnsEnvironment getSandboxEnvironment()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |