On Wednesday 11 September 2002 2:39 pm, Lars Gullik Bjønnes 
wrote:
> This is how I think this should be done.

> lyx<->lyxserver--localsocket--pipesocket(as a socketclient)
>                        \
>                          socketclient
>
> what I mean is that the localsocket is the native interface,
> and to named pipe is just built on top of this.
>
> There should be no need to special case pipes _inside_ lyx, it
> is better off as an external program/daemon.
>
> then lyx need only to handle the localsocket (or unix socket)
> properly.

welll I have lyx<->lyxserver<->pipestream

where pipestream is one of the things below (this being 
pipestreamfwd.h)

Similarly, mathed's interaction with things like maple would be

mathed<->maplepipestream.

Currently, pipestream makes the file device visible so that it 
can be monitored, but eventually I planned to move fdmonitor 
inside the pipestream and simply have a boost::function0<void> 
tell the outside world (pipestream owner) that something new had 
arrived to be read.

As you can see, Ive thought about this and think that my way 
works and works well. Have a look at the code ;-)

Angus

template<typename commT,
        typename charT, typename traitsT = std::char_traits<charT> >
class basic_fdbuf;

template<typename Buffer,
        typename charT, typename traitsT = std::char_traits<charT> >
class basic_pipestream;

class PipeCommClient;
class PipeCommServer;

typedef basic_fdbuf<PipeCommClient, char> fdbuf_client;
typedef basic_fdbuf<PipeCommServer, char> fdbuf_server;

typedef basic_pipestream<fdbuf_client, char> pipestream_client;
typedef basic_pipestream<fdbuf_client, char> pipestream_server;

typedef basic_fdbuf<PipeCommClient, wchar_t> wfdbuf_client;
typedef basic_fdbuf<PipeCommServer, wchar_t> wfdbuf_server;

typedef basic_pipestream<fdbuf_client, wchar_t> 
wpipestream_client;
typedef basic_pipestream<fdbuf_client, wchar_t> 
wpipestream_server;

Reply via email to