• Post Reply Bookmark Topic Watch Topic
  • New Topic

Converting a blocking call to non blocking  RSS feed

 
Thomas Smets
Ranch Hand
Posts: 111
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ok,
The problem is rather simple, I want to convert a blocking call into a non-blocking call.
The solution I came up with is not working for an obvious reason : To "quit" the thread it has to be over & the other thread is stil running...
Could someone propose a better idea (or a working one )

Thomas SMETS,
SCJP, Brussels
--

[ April 24, 2002: Message edited by: Thomas SMETS ]
 
Thomas Smets
Ranch Hand
Posts: 111
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For the one interested here is the solution :

Firstly the blocking call :

Secondly a quick wrapper class :

Fianlly the call :

Thomas SMETS,
SCJP - Brussels
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!