Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [tcf-dev] Can the Java implementation be turned into a full peer clients can connect to?

Hi Uwe,

 

How about org.eclipse.tcf.core.ServerTCP? I had once tried it and it works as a normal discoverable peer. Try the following code:

              Protocol.invokeLater(new Runnable(){

                     @Override

                     public void run() {

                           try {

                                  new ServerTCP("My TCF Server", 1534);

                           } catch (IOException e) {

                                  e.printStackTrace();

                           }

                     }});

Then you can add an IServiceProvider to register services like below:

        ServiceManager.addServiceProvider(new IServiceProvider() {

 

            public IService[] getLocalService(final IChannel channel) {

                channel.addCommandServer(locator, new IChannel.ICommandServer() {

                    public void command(IToken token, String name, byte[] data) {

                        locator.command((AbstractChannel)channel, token, name, data);

                    }

                });

                return new IService[]{ locator };

            }

 

            public IService getServiceProxy(IChannel channel, String service_name) {

                return null;

            }

        });

 

-William

 

-----Original Message-----
From: tcf-dev-bounces@xxxxxxxxxxx [mailto:tcf-dev-bounces@xxxxxxxxxxx] On Behalf Of Stieber, Uwe
Sent: Wednesday, July 31, 2013 6:52 PM
To: TCF Development (tcf-dev@xxxxxxxxxxx)
Subject: [tcf-dev] Can the Java implementation be turned into a full peer clients can connect to?

 

Hi guys,

 

Here is one question which got raised while looking for a way to script UI and headless Eclipse instances for our product. We know that the Java implementation contains everything for being a client. The question is if the Java TCF implementation does contain all the necessary code to basically turn Eclipse into a discoverable peer other clients, like a shell implementation, can connect to? And if yes, how to enable it?

 

Thanks, Best regards, Uwe :)

_______________________________________________

tcf-dev mailing list

tcf-dev@xxxxxxxxxxx

https://dev.eclipse.org/mailman/listinfo/tcf-dev


Back to the top