From: Clayton H. <cla...@sp...> - 2003-11-01 18:40:44
|
Hi Steve, =20 I have checked out the changes you made for the console application and had the following notes: 1) Missing comments for public methods/ constructors cause the nant build to fail. You can simulate this in vs.net by changing the "treat warning as errors" on and specifying an output filename for the xml documentation file. =20 - Also on a related note, feel free to check in your vs.net solution and project, there may be developers that like using vs.net that would be happy with this...although in the end the nightly build only cares about if it builds with nant or not so it has to build with that... 2) There may need to be some re-work done on the Commands piece: a) (optional) How do you feel about calling the namespace Command, to make it closer to the library namespaces? I don't know if this would be better/ worse, just would make it more consistent...thoughts? b) The work being done in the constructor should be moved to a method and called separately. One good pattern for this is the Command Pattern, which is used on the library side of things. Basically just an execute method for all commands, and an interface to make it possible to call many different commands in the same way. Here are a couple of pages on it: - http://c2.com/cgi/wiki?CommandPattern <http://c2.com/cgi/wiki?CommandPattern>=20 - http://www.javaworld.com/javaworld/javatips/jw-javatip68.html <http://www.javaworld.com/javaworld/javatips/jw-javatip68.html>=20 3) Would it be possible to move the command execution outside of the Parser section? I am not sure where it should live but I find it a little confusing where it is. It might be okay in ConsoleMain? Any thoughts/ ideas on this would be great. =20 =20 Cheers, =20 =20 Clayton |
From: Steve K. <s.k...@co...> - 2003-11-01 21:37:05
|
Hello Clayton, 1) I have added all the comments for the public methods and = constructors. Thanks for telling me this. What time is the build every evening? I am = in Seattle, WA.=20 2a) I didn't change the namespace to Command because I see in the = library it is Commands. 2b) I did move the code from the constructor to the execute methods. I believe this solved my hanging problem I emailed you able. Thanks. 3) I did this suggestion. I was struggling with how to use cvsroot over = and over for each command. This solves my issue. Thanks. I have committed the code and added the solution and project files for = the cvs console. I will finish up the options for the checkout command and = work on the Login and passwd commands. =20 Steve Kenzell, MCP > -----Original Message----- > From: Clayton Harbour [mailto:cla...@sp...] > Sent: Saturday, November 01, 2003 11:00 AM > To: Steve Kenzell > Cc: SharpCVSLib Developer List > Subject: Console changes >=20 > Hi Steve, >=20 >=20 >=20 > I have checked out the changes you made for the console application = and > had the following notes: >=20 > 1) Missing comments for public methods/ constructors cause > the nant build to fail. You can simulate this in vs.net by changing = the > "treat warning as errors" on and specifying an output filename for the > xml documentation file. >=20 > - Also on a related note, feel free to check in your vs.net solution = and > project, there may be developers that like using vs.net that would be > happy with this...although in the end the nightly build only cares = about > if it builds with nant or not so it has to build with that... >=20 > 2) There may need to be some re-work done on the Commands > piece: >=20 > a) (optional) How do you feel about calling = the > namespace Command, to make it closer to the library namespaces? I = don't > know if this would be better/ worse, just would make it more > consistent...thoughts? >=20 > b) The work being done in the constructor = should > be moved to a method and called separately. One good pattern for this > is the Command Pattern, which is used on the library side of things. > Basically just an execute method for all commands, and an interface to > make it possible to call many different commands in the same way. = Here > are a couple of pages on it: >=20 > - > http://c2.com/cgi/wiki?CommandPattern > <http://c2.com/cgi/wiki?CommandPattern> >=20 > - > http://www.javaworld.com/javaworld/javatips/jw-javatip68.html > <http://www.javaworld.com/javaworld/javatips/jw-javatip68.html> >=20 > 3) Would it be possible to move the command execution > outside of the Parser section? I am not sure where it should live but = I > find it a little confusing where it is. It might be okay in > ConsoleMain? Any thoughts/ ideas on this would be great. >=20 >=20 >=20 >=20 >=20 > Cheers, >=20 >=20 >=20 >=20 >=20 > Clayton |
From: Gerald E. <gn...@f2...> - 2003-11-02 00:29:29
|
I have re-enabled the code for generating the events to allow M, E and MT responses to be received by any application using #cvslib. I have also removed a Console.WriteLine() within CVSServerConnection::SendMessage() as it's the calling applications responsibility for communicating with the user (although this was probably only put in for debugging). I've not changed any of the existing logging, but I suspect that we are going to find that every time we get a response back from the server, we will end up logging it multiple times. Use of this event is similar to the Response/RequestMessage events in that the app will need code like: connection.MessageEvent.MessageEvent += new EncodedMessage.MessageHandler(OnMessage); One major difference is that this event will get fired once for each line from the server. Note: Other messages generated internally by #cvslib are also fired through this event. I'm not convinced this is the best way to do this, but seeing as it was existing code I have decided to leave it as it was. We may need to revisit this. Finally there is a minor bug in CvsStream.ReadLine() which causes problems for responses without arguments, but I'll deal with this in the morning. Gerald. |