Hi,
This is santosh Kumar ,I am struck with SIP Communicator code development . I have configured eclips work space by following http://www.jitsi.org/index.php/Documentation/ConfigureEclipseNew#toc3 this procedure and now it loads all the libraries and files . I want to integrate that sip communicator code with Poling activity(PolingServer.java which i written to poll) . It means I am poling one activity based on that i keep calling CallManager.java
but here i am facing problem . its giving Class Not Found Exception. How should i call my won package class to other packages in SIP COmmunicator src dir? what should i do to integrate my code with original code ? why i couldnt able to communicate with other classes which are in other directories.
It sounds related to OSGi i.e. the fact that different
directories/packages are in different bundles/plug-ins and they have
to appropriately use Export-Package and Import-Package in the
respective .manifest.mf files in order to cross bundle boundaries.
You likely need to read about OSGi and Felix and examine our code
further.
but here i am facing problem . its giving Class Not Found Exception. How
should i call my won package class to other packages in SIP COmmunicator src
dir? what should i do to integrate my code with original code ? why i
couldnt able to communicate with other classes which are in other
directories.
It may be, but i created one class in net.java.sip.communicator.launcher package. i given this package Export and import permissions in swing.ui.manifest.mf file ( impl.gui.GuiActivator) still i couldnt able to call to CallManager.java which is under net.java.sip.communicator.impl.gui.main.call package. .. And please let me know from where i can call to CallManager.java ..
This is is the code i should make it working to make call but its not allowing me . from wich package i can make a call
On Tue, Mar 29, 2011 at 7:14 AM, venkat santosh > <venkat_santosh@hotmail.com> wrote:
> but here i am facing problem . its giving Class Not Found Exception. How
> should i call my won package class to other packages in SIP COmmunicator src
> dir? what should i do to integrate my code with original code ? why i
> couldnt able to communicate with other classes which are in other
> directories.
It sounds related to OSGi i.e. the fact that different
directories/packages are in different bundles/plug-ins and they have
to appropriately use Export-Package and Import-Package in the
respective .manifest.mf files in order to cross bundle boundaries.
You likely need to read about OSGi and Felix and examine our code
further.
It may be, but i created one class in net.java.sip.communicator.launcher
package. i given this package Export and import permissions in
swing.ui.manifest.mf file ( impl.gui.GuiActivator) still i couldnt able
to call to CallManager.java which is under
net.java.sip.communicator.impl.gui.main.call package. .. And please let me
know from where i can call to CallManager.java ..
The launcher package isn't an OSGi bundle, it just does what it says: Launching Jitsi by starting OSGi.
This is is the code i should make it working to make call but its not
allowing me . from wich package i can make a call
List<ProtocolProviderService> telephonyProviders =
CallManager.getTelephonyProviders();
System.out.println("telephonyProviders="+telephonyProviders);
CallManager.createCall(telephonyProviders.get(0), "4003001");
To access the CallManager like that, you either need to place your class in the impl.gui package or into a package created by your own (including a manifest importing the gui bundle and exporting the impl.gui in the gui's manifest (very bad idea)).
-> Create your own bundle, put it into the launch configuration (felix.client.run.properties) and take the method GuiActivator. getRegisteredProviders as a starting point for accessing the providers directly (as Emil suggested).
It may be, but i created one class in net.java.sip.communicator.launcher
package. i given this package Export and import permissions in
swing.ui.manifest.mf file ( impl.gui.GuiActivator) still i couldnt able to
call to CallManager.java which is under
net.java.sip.communicator.impl.gui.main.call package. .. And please let me
know from where i can call to *CallManager.java* ..
The CallManager class is not meant for external use. You should access the
providers directly.
You should have a look at our developer documentation and, as Lubomir
mentioned, read Felix/OSGi related docs on our or their site.
>
> On Tue, Mar 29, 2011 at 7:14 AM, venkat santosh > > <venkat_santosh@hotmail.com> wrote:
> > but here i am facing problem . its giving Class Not Found Exception.
How
> > should i call my won package class to other packages in SIP
COmmunicator src
> > dir? what should i do to integrate my code with original code ? why i
> > couldnt able to communicate with other classes which are in other
> > directories.
>
> It sounds related to OSGi i.e. the fact that different
> directories/packages are in different bundles/plug-ins and they have
> to appropriately use Export-Package and Import-Package in the
> respective .manifest.mf files in order to cross bundle boundaries.
> You likely need to read about OSGi and Felix and examine our code
> further.