net.rim.pushsdk.commons
Class SQLPropertiesImpl

java.lang.Object
  extended by net.rim.pushsdk.commons.SQLPropertiesImpl
All Implemented Interfaces:
SQLProperties

public class SQLPropertiesImpl
extends Object
implements SQLProperties

Default implementation of SQLProperties.

This class will load the SQL statement(s) out of the mysql.properties or oracle.properties file depending on the value of the database.type in the PushSDK.properties file.

If you want to use a different database other than 'mysql' or 'oracle', you can create you own implementation that loads the SQL out of a properties file or any other location of your choosing. Note: Your data access implementation (DAO) must support the database type you choose to use.

Dependencies that must be injected to properly initialize this object for use:
- pushSDKProperties

Author:
dstrelbytsky

Field Summary
 
Fields inherited from interface net.rim.pushsdk.commons.SQLProperties
DATABASE_TYPE_MYSQL, DATABASE_TYPE_ORACLE, PUSH_APP_ADD, PUSH_APP_CHANGE_ENTERPRISE_CREDENTIALS, PUSH_APP_CHANGE_PUBLIC_CREDENTIALS, PUSH_APP_CHANGE_TYPE_FROM_ENTERPRISE_TO_PUBLIC_AND_ENTERPRISE, PUSH_APP_CHANGE_TYPE_FROM_PUBLIC_TO_PUBLIC_AND_ENTERPRISE, PUSH_APP_DELETE, PUSH_APP_DISABLE, PUSH_APP_ENABLE, PUSH_APP_ENABLE_WITH_EXPIRY, PUSH_APP_FIND_ALL, PUSH_APP_FIND_BY_ID, PUSH_APP_FIND_BY_NAME, PUSH_APP_FIND_BY_STATUS, PUSH_APP_FIND_BY_TYPE, PUSH_APP_UPDATE, PUSH_COUNT_ADD, PUSH_COUNT_INCREMENT, PUSH_COUNT_REMOVE, PUSH_REQUEST_ADD, PUSH_REQUEST_DELETE, PUSH_REQUEST_DELETE_BY_APPID, PUSH_REQUEST_DELETE_BY_APPID_AND_DATE, PUSH_REQUEST_DELETE_BY_DATE, PUSH_REQUEST_DELETE_BY_PUSHID, PUSH_REQUEST_DELETE_BY_PUSHIDS, PUSH_REQUEST_DELETE_COMPLETED, PUSH_REQUEST_DELETE_COMPLETED_BY_APPID, PUSH_REQUEST_DELETE_COMPLETED_BY_APPID_AND_DATE, PUSH_REQUEST_DELETE_COMPLETED_BY_DATE, PUSH_REQUEST_DETAIL_ADD, PUSH_REQUEST_DETAIL_FIND_BY_DATE_RANGE, PUSH_REQUEST_DETAIL_FIND_BY_ID, PUSH_REQUEST_DETAIL_FIND_BY_ID_AND_ADDRESS, PUSH_REQUEST_DETAIL_FIND_BY_ID_AND_ADDRESSES, PUSH_REQUEST_DETAIL_FIND_BY_ID_AND_STATES, PUSH_REQUEST_DETAIL_FIND_BY_ID_AND_STATUS_CODE, PUSH_REQUEST_DETAIL_FIND_BY_ID_AND_SUBSCRIBER_IDS, PUSH_REQUEST_DETAIL_FIND_BY_STATUS_CODE, PUSH_REQUEST_DETAIL_FIND_ID_AND_APPID_BY_IDS_AND_STATE, PUSH_REQUEST_DETAIL_FIND_ID_AND_APPID_BY_STATE, PUSH_REQUEST_DETAIL_GET_SIZE_BY_DATE_RANGE, PUSH_REQUEST_DETAIL_UPDATE, PUSH_REQUEST_DETAIL_UPDATE_WITHOUT_ADDRESS, PUSH_REQUEST_FIND_ALL, PUSH_REQUEST_FIND_BY_APPID, PUSH_REQUEST_FIND_BY_DATE_RANGE, PUSH_REQUEST_FIND_BY_ID, PUSH_REQUEST_FIND_BY_STATUS, PUSH_REQUEST_FIND_INCOMPLETE, PUSH_REQUEST_FIND_INCOMPLETE_BY_APPID_AND_SUBID, PUSH_REQUEST_GET_SIZE_BY_DATE_RANGE, PUSH_REQUEST_UPDATE, PUSH_STATS_ADD, PUSH_STATS_GET_STATS, PUSH_STATS_RESET_RUNNING_CONTENT_SUM, PUSH_STATS_RESET_RUNNING_PUSH_COUNT, PUSH_STATS_UPDATE, SUBSCRIPTION_DELETE_INACTIVE_SUBSCRIPTION, SUBSCRIPTION_DELETE_SUBSCRIPTIONS, SUBSCRIPTION_FIND_BY_ADDRESS_AND_ID_AND_NOT_STATUS, SUBSCRIPTION_FIND_BY_ADDRESS_AND_NOT_ID_AND_NOT_STATUS, SUBSCRIPTION_FIND_BY_APPID, SUBSCRIPTION_FIND_BY_APPID_AND_ADDRESS, SUBSCRIPTION_FIND_BY_APPID_AND_ID, SUBSCRIPTION_FIND_BY_APPID_AND_INACTIVE_STATUS, SUBSCRIPTION_FIND_BY_APPID_AND_INACTIVE_STATUS_AND_TYPE, SUBSCRIPTION_FIND_BY_APPID_AND_INACTIVE_STATUS_AND_TYPE_INDEX, SUBSCRIPTION_FIND_BY_APPID_AND_INACTIVE_STATUS_INDEX, SUBSCRIPTION_FIND_BY_APPID_AND_STATUS, SUBSCRIPTION_FIND_BY_APPID_AND_STATUS_AND_IDS, SUBSCRIPTION_FIND_BY_APPID_AND_STATUS_AND_TYPE_NO_INDEX, SUBSCRIPTION_FIND_BY_APPID_AND_STATUS_NO_INDEX, SUBSCRIPTION_FIND_BY_APPID_AND_TYPE, SUBSCRIPTION_FIND_BY_APPID_AND_TYPE_AND_STATUS, SUBSCRIPTION_FIND_BY_ID, SUBSCRIPTION_FIND_BY_ID_AND_NOT_STATUS, SUBSCRIPTION_FIND_BY_ID_AND_STATUS, SUBSCRIPTION_FIND_BY_ID_PATTERN, SUBSCRIPTION_GET_DEVICEMODEL_COUNT, SUBSCRIPTION_GET_FAILED_PUSH_COUNT, SUBSCRIPTION_GET_MODEL_COUNT_BY_STATUS, SUBSCRIPTION_GET_OSVERSION_COUNT, SUBSCRIPTION_GET_OSVERSION_COUNT_BY_STATUS, SUBSCRIPTION_GET_RESUME_COUNT, SUBSCRIPTION_GET_SIZE_BY_APPID, SUBSCRIPTION_GET_SIZE_BY_APPID_AND_STATUS, SUBSCRIPTION_GET_SIZE_BY_APPID_AND_TYPE, SUBSCRIPTION_GET_SIZE_BY_APPID_AND_TYPE_AND_STATUS, SUBSCRIPTION_GET_SIZE_BY_ID_PATTERN, SUBSCRIPTION_GET_SUBSCRIBE_COUNT, SUBSCRIPTION_GET_SUSPEND_COUNT, SUBSCRIPTION_GET_UNSUBSCRIBE_COUNT, SUBSCRIPTION_INCREMENT_FAILED_PUSH_COUNT, SUBSCRIPTION_PARTIALSUBSCRIBE, SUBSCRIPTION_RESET_FAILED_PUSH_COUNT, SUBSCRIPTION_RESUBSCRIBE, SUBSCRIPTION_RESUME, SUBSCRIPTION_SUBSCRIBE, SUBSCRIPTION_SUSPEND, SUBSCRIPTION_UNSUBSCRIBE, SUBSCRIPTION_UPDATE_FAILED_PUSH_COUNT
 
Constructor Summary
SQLPropertiesImpl()
           
 
Method Summary
 String getProperty(String property)
          Returns the value for the given property name.
 void setPushSDKProperties(PushSDKProperties pushSDKProperties)
          Support for dependency injection.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SQLPropertiesImpl

public SQLPropertiesImpl()
Method Detail

getProperty

public String getProperty(String property)
Description copied from interface: SQLProperties
Returns the value for the given property name.

Specified by:
getProperty in interface SQLProperties
Parameters:
property - the key name
Returns:
the property string value

setPushSDKProperties

public void setPushSDKProperties(PushSDKProperties pushSDKProperties)
Description copied from interface: SQLProperties
Support for dependency injection. Inject an implementation of PushSDKProperties.

Specified by:
setPushSDKProperties in interface SQLProperties
Parameters:
pushSDKProperties - an instance of the PushSDKProperties implementation


Copyright © 2011 Research In Motion. All Rights Reserved.