commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stig Tollefsen <...@antares.no>
Subject [NNTPClient usage]
Date Mon, 10 Feb 2003 18:13:58 GMT
I'm a newbie here, so bear with me:

I'm using the net.nntp package, and this poses a few problems:
I need to issue NNTP extension commands (like XOVER), and this is easy 
using the sendCommand() method of the NNTP base class. I can get the 
reply string using the getReplyString() method. What is baffling me is 
that there seems to be no way of reading the command result string from 
the socket stream. NNTPClient implements this by reading lines from the 
_reader BufferedReader instance in NNTP, which wraps SocketClient's 
_input_ InputStream instance. Now, _input_ has protected access scope, 
while _reader has package scope. This means that in order to read from 
(or write to) the stream, the client has to be in the same package as 
NNTP and NNTPClient.

Shouldn't _reader, _writer and _isAllowedToPost have (at least) 
protected access scope in NNTP, or alternatively be accessible via 
accessor methods?

Stig Tollefsen
Antares Development
www.antares.no
sto@antares.no


Mime
View raw message