On Fri, Oct 10, 2014 at 11:55:32AM -0400, Bing Wang wrote:
>    Hi, Dave,
>    I used the namespace option to generate the api python file. I found
>    that GenerateDS always put the namespace definition for each new
>    element, so I saw xmlns:****** for each new elements. I am wondering if
>    I could remove them since I have the namespace definition at the top of
>    the file.

Here are two things that you might look at (although you've likely
already noticed them):

- generateDS.py has a command line option: --namespacedef.  You can
  get a small amount of information about it by using --help.  And,
  also see the documentation:
  http://www.davekuhlman.org/generateDS.html#running-generateds-py

- The 'export' method in each generated class has an optional
  parameter namespacedef_.  It may help you control whether the export
  method generates a namespace definition and what the definition is.

Check the call to the export method in the 'parse' function (near
the bottom of a generated .py file) and also calls to the export
method in classes for child elements in several of your generated
classes.  That might give you a clue about controlling this.

Hope this helps.  If you want me to look at it a more closely, send
me your XML schema and the command you use to run generateDS.py.

>    By the way, I really like generateDS. It's wonderful.
>    Thank you!

You are welcome.  Glad to hear that it's useful.

Dave



-- 

Dave Kuhlman
http://www.davekuhlman.org

------------------------------------------------------------------------------
Meet PCI DSS 3.0 Compliance Requirements with EventLog Analyzer
Achieve PCI DSS 3.0 Compliant Status with Out-of-the-box PCI DSS Reports
Are you Audit-Ready for PCI DSS 3.0 Compliance? Download White paper
Comply to PCI DSS 3.0 Requirement 10 and 11.5 with EventLog Analyzer
http://p.sf.net/sfu/Zoho
_______________________________________________
generateds-users mailing list
generateds-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/generateds-users

Reply via email to