Technology Blogs by SAP
Learn how to extend and personalize SAP applications. Follow the SAP technology blog for insights into SAP BTP, ABAP, SAP Analytics Cloud, SAP HANA, and more.
Showing results for 
Search instead for 
Did you mean: 
Product and Topic Expert
Product and Topic Expert
0 Kudos

BlackBerry Connection Settings (In Eclipse)


Here is second part of HWC customization for BlackBerry. It will illustrate how we can keep the settings unchanged itself rather than passing from device each time.


Part I : Changing the HWC image and brandName


below is the connection settings screen in BlackBerry.





1. Open file.




2. For server name:


    find the getDefaultConnectionServerName()  method.



public String getDefaultConnectionServerName() throws MessagingClientException


String property = (String)MessagingClientLib.getInstance().getConfigProperty( PropertyID.CONNECTION_SERVER_NAME );


property = "";

return property;


2. For Server Port:


    find the getDefaultConnectionServerPort()method.


public Integer getDefaultConnectionServerPort() throws MessagingClientException



Integer property = (Integer)MessagingClientLib.getInstance().getConfigPropert( PropertyID.CONNECTION_SERVER_PORT );

property = new Integer(443);

return property;


3. For Farm Id:


    find the getDefaultConnectionFarmId()method.




public String getDefaultConnectionFarmId() throws MessagingClientException


String property = (String)MessagingClientLib.getInstance().getConfigProperty( PropertyID.CONNECTION_FARM_ID );

property = "sup.test.msg";

return property;


4. For HTTP/HTTPS protocol:


    find the isDefaultConnectionHTTPS()method.


public Boolean isDefaultConnectionHTTPS() throws MessagingClientException


Boolean property =(Boolean)MessagingClientLib.getInstance().getConfigProperty( PropertyID.CONNECTION_USE_HTTPS );

property = Boolean.TRUE;

return property;



4. For Registration Type (manual/automatic/Auto Afaria Cert):


    find the getDefaultConnectionRegistrationMethod()method.



public Integer getDefaultConnectionRegistrationMethod() throws MessagingClientException


Integer property =(Integer)MessagingClientLib.getInstance().getConfigProperty( PropertyID.CONNECTION_AUTO_REGISTRATION_HINT );


property = new Integer(1);

// If anonymous access is desired, the registration type must be Automatic.


if ( isAnonymous() )



// Value for "Automatic" registration, this exposes the "Password" field in settings UI

property = new Integer( 1 );


return property;


If integer value is 1, it corresponds to manual registration

If integer value is 2, it corresponds to automatic registration and so on.