[ http://issues.apache.org/jira/browse/AXIS2C-269?page=comments#action_12433594 ] James Clark commented on AXIS2C-269: ------------------------------------
The output stream needs flush and close methods as well. > Try to clean up axis2_stream > ---------------------------- > > Key: AXIS2C-269 > URL: http://issues.apache.org/jira/browse/AXIS2C-269 > Project: Axis2-C > Issue Type: Improvement > Components: util > Affects Versions: Current (Nightly) > Reporter: James Clark > Priority: Minor > > For doing encryption and signing right, it will be important to have a clean, > minimal stream interface. axis2_stream is a bit crufty at the moment. > Specifically, the get_type method is bogus: if you have an OO type (which > stream should be), then you shouldn't have a method returning a type-code for > each implementation. It only seems to be used in > axis2_http_transport_utils_on_data_request. I don't understand what that's > doing, but I'm fairly sure get_type is not the best way to it. > I would also suggest having separate input and output streams (unless there > are really cases where you need to have a random access stream that can be > both read and written). > Having both get_char and read in an interface is a bad idea. Have just read. > You can implement get_char as a function on top of read. > unget is a bad idea on your fundamental stream type. If you really need it, > create a lookahead_stream derived from stream that provides this additional > operation and forwards to an underlying regular stream. Providing a peek > method is better than unget (it's clear what the semantics of multiple peeks > are). -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]