Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
New Developer
laety_Dev
Posts: 12
Registered: ‎04-24-2014
My Device: Developer

htpfilter protocol class not starting app from link on browser

[ Edited ]

Hi all,

 

I am facing some difficulties with HttpFilter.

 

I have read on a number of forum about calling HttpFilterRegistry.registerFilter("www.name.com","com.sample.httpFilter"); in the main to register the filter and 

implement a protocol class that will detect the www.name.com and run the app. 

However, so far, I have not manage to start the applicationn from the browser using the url I have in my project

 

I am probably missing something but I m not sure what it is.

I have tried the httpfilterdemo but still did not work.

 

a sample code I have tried is attached

Please use plain text.
Developer
peter_strange
Posts: 19,608
Registered: ‎07-14-2008
My Device: Not Specified

Re: htpfilter protocol class not starting app from link on browser

I suggest you read the documentation, then think about how you would describe, in words, what this API call actually does:

 

HttpFilterRegistry.registerFilter("www.name.co","com.sample.httpFilter");

 

Once you have figured out what this command does, then you will appreciate that you need to create a Protocol class with the package name "com.sample.httpFilter". 

Please use plain text.
New Developer
laety_Dev
Posts: 12
Registered: ‎04-24-2014
My Device: Developer

Re: htpfilter protocol class not starting app from link on browser

Hi,

 

I have read the documentation and I have already implemented a Protocol.java class in the package com.sample.httpFilter prior to posting my question here. I only put the 2 together in the attachment to show the code I have written.

I have tested the httpfilterdemo as well, still,the app does not start when I open the link from the browser. 

 

 

Please use plain text.