> From: Mike Vella <vellam...@gmail.com> >To: Dave Kuhlman <dkuhl...@rexx.com> >Cc: "generateds-users@lists.sourceforge.net" ><generateds-users@lists.sourceforge.net> >Sent: Friday, June 7, 2013 7:49 PM >Subject: Re: generateDS class renaming >
> That's great Dave, it will help me solve this issue > Mike - Attached (in a separate email) is a patched version of generateDS.py with the fix that you suggested. Or, you can get it from BitBucket using Mercurial: https://bitbucket.org/dkuhlman/generateds. With this fix, if you use this flag: --use-getter-setter=none generateDS.py will not generate getters and setters. Here is an explanation from the ammended documentation (generateDS.txt): use-getter-setter ``generateDS.py`` now generates getter and setter methods (for variable "abc", for example) with the names get_abc() and set_abc(), which I believe is a more Pythonic style, instead of getAbc() and setAbc(), which was the old behavior. Use this flag to generate getters and setters in the old style (getAbc() and setAbc()) or the newer style(get_abc() and set_abc()) which is the default or to omit generation of getter and setter methods. Possible values are: - "old" - Name getters/setters getVar()/setVar(). - "new" - Name getters/setters get_var()/set_var(). - "none" - Do not generate getter/setter methods. The default is "new". I suppose that we might argue that the default should be "none", but I worry that it would cause existing users some grief. Thanks again for this suggestion. It should have been added a long time ago. Some XML Schemas do produce huge files, and it's likely that others would like to trim those down, also. I'm likely to wait a bit before uploading a new version to the Python Package Index and SourgeForge.net. - Dave > > On 7 June 2013 03:51, Dave Kuhlman <dkuhl...@rexx.com> wrote: > > > Mike - > > > > Good to hear from you again. > > > > There is already an option --use-old-getter-setter. Perhaps we > > could replace that one with something like this: > > > > --getter-setter=[old|new|none] > > > > where "none" means "do not generate getters and setters. > > > > That's probably what it should have been in the first > > place. It should be reasonably easy to do. I'll take a look. > > > > And, thanks for the suggestion. > > > > - Dave > > > > > > > > -- > > > > > > Dave Kuhlman > > http://www.rexx.com/~dkuhlman > -- Dave Kuhlman http://www.rexx.com/~dkuhlman ------------------------------------------------------------------------------ This SF.net email is sponsored by Windows: Build for Windows Store. http://p.sf.net/sfu/windows-dev2dev _______________________________________________ generateds-users mailing list generateds-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/generateds-users