|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.rim.pushsdk.pushappmgmt.PushApplicationServiceImpl
public abstract class PushApplicationServiceImpl
Implementation of the PushApplicationService interface.
Dependencies that must be injected to properly initialize this object for use:
| Constructor Summary | |
|---|---|
PushApplicationServiceImpl()
|
|
| Method Summary | |
|---|---|
void |
addPushApplication(PushApplication pushApplication)
Adds the specified push application to the persistent store. |
void |
changePushApplicationCredentials(String id,
String currentUsername,
String newUsername,
String currentPassword,
String newPassword,
String modifiedBy)
Deprecated. |
void |
changePushApplicationEnterpriseCredentials(String id,
String currentUsername,
String newUsername,
String currentPassword,
String newPassword,
String modifiedBy)
Change the enterprise username and password of a push application that has a type of Enterprise Push or Public+Enterprise Push. |
void |
changePushApplicationPublicCredentials(String id,
String currentPassword,
String newPassword,
String modifiedBy)
Change the public password of a push application that has a type of Public Push, Web Signal, or Public+Enterprise Push. |
void |
changePushApplicationTypeFromEnterpriseToPublicAndEnterprise(String id,
String publicPassword,
String publicNotifyUrl,
String modifiedBy)
Changes the type of a push application from Enterprise Push to Public+Enterprise Push. |
void |
changePushApplicationTypeFromPublicToPublicAndEnterprise(String id,
String enterpriseUsername,
String enterprisePassword,
String enterpriseNotifyUrl,
String modifiedBy)
Changes the type of a push application from Public Push to Public+Enterprise Push. |
protected abstract PushAppSubDeleteManager |
createPushAppSubDeleteManager()
Create a new instance of a PushAppSubDeleteManager for use by the deletion method. |
protected abstract PushAppUnsubscribeManager |
createPushAppUnsubscribeManager()
Create a new instance of a PushAppUnsubscribeManager for use by the deletion method. |
void |
deletePushApplication(String id,
String deletedBy,
boolean shouldUnsubscribeBeforeDelete)
Warning! Removes a push application and any related entities entirely and permanently from the persistent store. |
void |
disablePushApplication(String id,
String modifiedBy)
Disables (sets to inactive) a push application. |
void |
enablePushApplication(String id,
Date expiryDate,
String modifiedBy)
Enables (sets to active) a push application. |
List<PushApplication> |
findAll()
Finds a list of all the push applications in storage. |
PushApplication |
findById(String id)
Finds the push application with the specified push application id. |
PushApplication |
findByIdAndValidate(String pushApplicationId)
Finds the push application with the specified push application id and validates the push application. |
PushApplication |
findByName(String name)
Finds the push application with the specified name. |
List<PushApplication> |
findByStatus(PushApplicationStatus status)
Finds a list of push applications with the specified status. |
List<PushApplication> |
findByType(PushApplicationType type)
Finds a list of push applications with the specified type. |
void |
setPushApplicationDAO(PushApplicationDAO pushApplicationDAO)
Support for dependency injection. |
void |
setPushSDKProperties(PushSDKProperties pushSDKProperties)
Support for dependency injection. |
void |
setPushStatsDAO(PushStatsDAO pushStatsDAO)
Support for dependency injection. |
void |
updatePushApplication(PushApplication pushApplication)
Updates the details of a push application. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public PushApplicationServiceImpl()
| Method Detail |
|---|
public void setPushApplicationDAO(PushApplicationDAO pushApplicationDAO)
PushApplicationServicePushApplicationDAO to use.
setPushApplicationDAO in interface PushApplicationServicepushApplicationDAO - an instance of a PushApplicationDAO implementationpublic void setPushSDKProperties(PushSDKProperties pushSDKProperties)
PushApplicationServicePushSDKProperties implementation.
setPushSDKProperties in interface PushApplicationServicepushSDKProperties - an instance of a PushSDKProperties implementationpublic void setPushStatsDAO(PushStatsDAO pushStatsDAO)
PushApplicationServicePushStatsDAO to use.
setPushStatsDAO in interface PushApplicationServicepushStatsDAO - the Push Stats Data Access Object
public void addPushApplication(PushApplication pushApplication)
throws InvalidPushAppException,
PushSDKException
PushApplicationService
addPushApplication in interface PushApplicationServicepushApplication - the push application to add
InvalidPushAppException - if a push application already exists with the given id or name
PushSDKException - if any other errors occur
public PushApplication findById(String id)
throws PushSDKException
PushApplicationService
findById in interface PushApplicationServiceid - the id of the push application to lookup
PushSDKException - if any other errors occur
public List<PushApplication> findByStatus(PushApplicationStatus status)
throws PushSDKException
PushApplicationService
findByStatus in interface PushApplicationServicestatus - the status of a push application
PushSDKException - if any other errors occurPushApplicationStatus
public List<PushApplication> findByType(PushApplicationType type)
throws PushSDKException
PushApplicationService
findByType in interface PushApplicationServicetype - the type of a push application
PushSDKException - if any other errors occurPushApplicationType
public List<PushApplication> findAll()
throws PushSDKException
PushApplicationService
findAll in interface PushApplicationServicePushSDKException - if any other errors occur
public void disablePushApplication(String id,
String modifiedBy)
throws InvalidPushAppException,
PushSDKException
PushApplicationService
disablePushApplication in interface PushApplicationServiceid - the id of the push applicationmodifiedBy - the user that disabled the push application
InvalidPushAppException - if the push application could not be found or is already disabled
PushSDKException - if any other errors occur
public void enablePushApplication(String id,
Date expiryDate,
String modifiedBy)
throws InvalidPushAppException,
PushSDKException
PushApplicationService
enablePushApplication in interface PushApplicationServiceid - the id of the push applicationexpiryDate - the new expiry date for the push application; if null is specified, the expiry date will remain unchangedmodifiedBy - the user that enabled the push application
InvalidPushAppException - if the push application could not be found or is already enabled
PushSDKException - if any other errors occur
public void deletePushApplication(String id,
String deletedBy,
boolean shouldUnsubscribeBeforeDelete)
throws InvalidPushAppException,
PushSDKException
PushApplicationService
deletePushApplication in interface PushApplicationServiceid - the id of the push application to remove entirely and permanentlydeletedBy - an identifier that identifies the caller of this API. The deletedBy value will be placed into the log files at
info level for audit purposesshouldUnsubscribeBeforeDelete - whether or not to unsubscribe the users of this push application from the content provider and the PPG (if the
PPG supports subscription) before performing the delete operation; a value of 'true' will ensure that the
onAutomaticUnsubscribe method is called in the ContentProviderSubscriptionService
interface. By implementing onAutomaticUnsubscribe you can perform any of your own application's
custom logic for each subscriber being auto unsubscribed
InvalidPushAppException - if the push application could not be found
PushSDKException - if any other errors occur
public PushApplication findByIdAndValidate(String pushApplicationId)
throws InvalidPushAppException,
PushSDKException
PushApplicationService
findByIdAndValidate in interface PushApplicationServicepushApplicationId - the id of the push application to lookup
InvalidPushAppException - if the push application specified fails validation
PushSDKException - if any other errors occur
public PushApplication findByName(String name)
throws PushSDKException
PushApplicationService
findByName in interface PushApplicationServicename - the name of the push application to lookup
PushSDKException - if any other errors occur
public void updatePushApplication(PushApplication pushApplication)
throws InvalidPushAppException,
PushSDKException
PushApplicationServiceIllegalArgumentException if the credentials are attempted to
be changed.
updatePushApplication in interface PushApplicationServicepushApplication - the updated push application
InvalidPushAppException - if the push application could not be found or another push application already exists with the updated name
PushSDKException - if any other errors occur
public void changePushApplicationTypeFromPublicToPublicAndEnterprise(String id,
String enterpriseUsername,
String enterprisePassword,
String enterpriseNotifyUrl,
String modifiedBy)
throws InvalidPushAppException,
PushSDKException
PushApplicationService
changePushApplicationTypeFromPublicToPublicAndEnterprise in interface PushApplicationServiceid - the id of the push applicationenterpriseUsername - an optional username for enterprise (BES) pushes; null if not requiredenterprisePassword - an optional password for enterprise (BES) pushes; null if not requiredenterpriseNotifyUrl - a full notification URL for enterprise (BES) acknowledgements; null if using a service level of Push EssentialsmodifiedBy - the user that is changing the push application's type
InvalidPushAppException - if the push application could not be found or is of an incorrect type
PushSDKException - if any other errors occurPushApplicationType
public void changePushApplicationTypeFromEnterpriseToPublicAndEnterprise(String id,
String publicPassword,
String publicNotifyUrl,
String modifiedBy)
throws InvalidPushAppException,
PushSDKException
PushApplicationServiceupdatePushApplication method. This method can then be called.
changePushApplicationTypeFromEnterpriseToPublicAndEnterprise in interface PushApplicationServiceid - the id of the push applicationpublicPassword - a password for public (BIS) pushespublicNotifyUrl - a notification URL fragment for public (BIS) acknowledgements; null if using a service level of Push EssentialsmodifiedBy - the user that is changing the push application's type
InvalidPushAppException - if the push application could not be found or is of an incorrect type
PushSDKException - if any other errors occurPushApplicationType
@Deprecated
public void changePushApplicationCredentials(String id,
String currentUsername,
String newUsername,
String currentPassword,
String newPassword,
String modifiedBy)
throws InvalidPushAppException,
IncorrectUsernameException,
IncorrectPasswordException,
PushSDKException
PushApplicationService
changePushApplicationCredentials in interface PushApplicationServiceid - the id of the push applicationcurrentUsername - the current username of the push application (Note: for an application with a type of Public Push, this
parameter is ignored, since it needs to match the id.)newUsername - the new username for the push application (Note: for an application with a type of Public Push, this parameter
is ignored, since it needs to match the id.)currentPassword - the current password of the push applicationnewPassword - the new password for the push applicationmodifiedBy - the user that is changing the push application's credentials
InvalidPushAppException - if the push application could not be found
IncorrectUsernameException - if the current username does not match the username found for the push application in storage
IncorrectPasswordException - if the current password does not match the password found for the push application in storage
PushSDKException - if any other errors occur
public void changePushApplicationPublicCredentials(String id,
String currentPassword,
String newPassword,
String modifiedBy)
throws InvalidPushAppException,
IncorrectPasswordException,
PushSDKException
PushApplicationService
changePushApplicationPublicCredentials in interface PushApplicationServiceid - the id of the push applicationcurrentPassword - the current password of the push applicationnewPassword - the new password for the push applicationmodifiedBy - the user that is changing the push application's public credentials
InvalidPushAppException - if the push application could not be found or is of an incorrect type
IncorrectPasswordException - if the current public password does not match the public password found for the push application in storage
PushSDKException - if any other errors occur
public void changePushApplicationEnterpriseCredentials(String id,
String currentUsername,
String newUsername,
String currentPassword,
String newPassword,
String modifiedBy)
throws InvalidPushAppException,
IncorrectUsernameException,
IncorrectPasswordException,
PushSDKException
PushApplicationService
changePushApplicationEnterpriseCredentials in interface PushApplicationServiceid - the id of the push applicationcurrentUsername - the current username of the push application (might be null)newUsername - the new username for the push application (might be null)currentPassword - the current password of the push application (might be null)newPassword - the new password for the push application (might be null)modifiedBy - the user that is changing the push application's enterprise credentials
InvalidPushAppException - if the push application could not be found or is of an incorrect type
IncorrectUsernameException - if the current enterprise username does not match the enterprise username for the push application in storage
IncorrectPasswordException - if the current enterprise password does not match the enterprise password found for the push application in
storage
PushSDKException - if any other errors occurprotected abstract PushAppUnsubscribeManager createPushAppUnsubscribeManager()
protected abstract PushAppSubDeleteManager createPushAppSubDeleteManager()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||