DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://nagoya.apache.org/bugzilla/show_bug.cgi?id=24191>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=24191 OptionBuilder only has static methods, yet many return an OptionBuilder instance Summary: OptionBuilder only has static methods, yet many return an OptionBuilder instance Product: Commons Version: unspecified Platform: Other OS/Version: Other Status: NEW Severity: Enhancement Priority: Other Component: CLI AssignedTo: [EMAIL PROTECTED] ReportedBy: [EMAIL PROTECTED] First of all, I think CLI is great. However, the OptionBuilder really gets my goat. All of the methods are static, yet all, except the create() methods, return an OptionBuilder instance. Presumably this is to allow us to chain calls to the builder, but by chaining calls, we are calling static methods through an instance, which is generally considered bad form. Also, it doesn't really qualify as an instance of the Builder Pattern in its current form since it does not meet the intent: 'Separate the construction of a complex object from its representation so that the same construction process can create different representations' (this is because of the static methods). Why not make the methods non-static and get the client to create an instance of the builder before proceeding? In it's current form, it seems a bit schizophrenic. Regards, Lance --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
