ecologylab / BigSemanticsWrapperRepository

Repository of wrappers used by the BigSemantics project.
Apache License 2.0
3 stars 9 forks source link

Bad namespaces in C# code generation #33

Closed amwebb closed 9 years ago

amwebb commented 9 years ago

C# requires that classes and namespaces not share the same name. Therefore, a "NS" is appended to namespaces during C# code generation. The recent restructuring created more hierarchical namespaces. Code generation does not take into account appending "NS" to inner namespaces. This creates code that will not compile.

For example:

Exhibition's namespace should be: Ecologylab.BigSemantics.Generated.Library.CreativeWorkNS.ExhibitionNS

But the code generator is currently creating: Ecologylab.BigSemantics.Generated.Library.CreativeWork.ExhibitionNS

and this conflicts with the class CreativeWork.

Proposed solution is to change repository xml to include "NS" for each package/namespace level, and remove appending NS in C# code generation.