Re: [fpc-pascal] returning a generic object?

2013-09-12 Thread Xiangrong Fang
TSelfType worked like a charm. Thanks! ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] IFPObserved

2013-09-12 Thread Graeme Geldenhuys
On 2013-09-11 07:02, Xiangrong Fang wrote: Where can I find detailed documentation on IFPObserved? It forms part of the Observer design pattern. The Observer design pattern works the same, irrespective of which language was used to implement it. So any Observer design pattern documentation

Re: [fpc-pascal] lnet for TCP daemon

2013-09-12 Thread Michael Schnell
On 09/11/2013 07:22 PM, Mark Morgan Lloyd wrote: I'd normally use a thread for this, but I've already got lnet's telnet client running in the program so would rather stick to the same library if possible. AFAIK, Lnet does not do threading internally (as does AsyncPro or - partly - Indy),

Re: [fpc-pascal] lnet for TCP daemon

2013-09-12 Thread Mark Morgan Lloyd
Michael Schnell wrote: On 09/11/2013 07:22 PM, Mark Morgan Lloyd wrote: I'd normally use a thread for this, but I've already got lnet's telnet client running in the program so would rather stick to the same library if possible. AFAIK, Lnet does not do threading internally (as does AsyncPro

Re: [fpc-pascal] lnet for TCP daemon

2013-09-12 Thread Dennis Poon
Mark Morgan Lloyd wrote: Is it feasible to use lnet for a simple TCP daemon on Linux, i.e. wait for a connection on a predefined port, read as much data as is available, repeat? And if so, what does the SerSock parameter to Accept() represent? I'd normally use a thread for this, but I've

Re: [fpc-pascal] DoDirSeparators and special filenames on Windows

2013-09-12 Thread Reimar Grabowski
On Thu, 12 Sep 2013 07:10:19 +0200 Jürgen Hestermann juergen.hesterm...@gmx.de wrote: Ahh, that's the reason: It's (another) sloppiness in Unix systems and has creeped into Windows from there. Unfortunately M$ hasn't implemented it correctly (like always) and enriched the experience with

Re: [fpc-pascal] DoDirSeparators and special filenames on Windows

2013-09-12 Thread Henry Vermaak
On Thu, Sep 12, 2013 at 12:01:30PM +0200, Reimar Grabowski wrote: On Thu, 12 Sep 2013 07:10:19 +0200 Jürgen Hestermann juergen.hesterm...@gmx.de wrote: Ahh, that's the reason: It's (another) sloppiness in Unix systems and has creeped into Windows from there. Unfortunately M$ hasn't

Re: [fpc-pascal] lnet for TCP daemon

2013-09-12 Thread Mark Morgan Lloyd
Mark Morgan Lloyd wrote: Michael Schnell wrote: On 09/11/2013 07:22 PM, Mark Morgan Lloyd wrote: I'd normally use a thread for this, but I've already got lnet's telnet client running in the program so would rather stick to the same library if possible. AFAIK, Lnet does not do threading

Re: [fpc-pascal] lnet for TCP daemon

2013-09-12 Thread Michael Schnell
On 09/12/2013 12:47 PM, Mark Morgan Lloyd wrote: I've concluded that using a thread is, in fact, preferable True. It's a pity that Synapse and friend (especially SynaSer) does does not implement internal threads that throw appropriate events in the Main Thread when something comes in (or

Re: [fpc-pascal] lnet for TCP daemon

2013-09-12 Thread Michael Van Canneyt
On Thu, 12 Sep 2013, Michael Schnell wrote: On 09/12/2013 12:47 PM, Mark Morgan Lloyd wrote: I've concluded that using a thread is, in fact, preferable True. It's a pity that Synapse and friend (especially SynaSer) does does not implement internal threads that throw appropriate events

Re: [fpc-pascal] lnet for TCP daemon

2013-09-12 Thread Mark Morgan Lloyd
Michael Schnell wrote: On 09/12/2013 12:47 PM, Mark Morgan Lloyd wrote: I've concluded that using a thread is, in fact, preferable True. It's a pity that Synapse and friend (especially SynaSer) does does not implement internal threads that throw appropriate events in the Main Thread when

Re: [fpc-pascal] lnet for TCP daemon

2013-09-12 Thread Marco van de Voort
In our previous episode, Mark Morgan Lloyd said: common request, and since the fpc-Team some time ago enabled TThread.Queue in the RTL, this is doable in a straight forward, fpc-ish way (portable but Delphi compatible). Although for certain types of usage being able to get directly to

Re: [fpc-pascal] lnet for TCP daemon

2013-09-12 Thread Michael Schnell
On 09/12/2013 01:28 PM, Michael Van Canneyt wrote: The very reason I use Synapse is that it DOES NOT use threads. Synapse is simple to use. Keep it so. Of course I don't vote for Synapse always using threads, but to provide _additional_ functions / objects (maybe units) that work similar to

Re: [fpc-pascal] lnet for TCP daemon

2013-09-12 Thread Marco van de Voort
In our previous episode, Michael Schnell said: The very reason I use Synapse is that it DOES NOT use threads. Synapse is simple to use. Keep it so. Of course I don't vote for Synapse always using threads, but to provide _additional_ functions / objects (maybe units) that work similar to

Re: [fpc-pascal] lnet for TCP daemon

2013-09-12 Thread Michael Schnell
On 09/12/2013 02:45 PM, Marco van de Voort wrote: E.g. TComport only starts an helper thread if you register receive events. If you do not, you can use it in a select/waitformultiple like way in a thread. Sounds good. I'm going to test this ASAP. -Michael