-
Notifications
You must be signed in to change notification settings - Fork 200
Module C Sharp XML
The C# module generates C# client code for accessing the SOAP endpoints and makes an attempt at compiling the code into a .NET assembly. If the the compile attempt is to be successful, then you must have a C# compiler available on your system path, or specify a compileExecutable
attribute in the Enunciate configuration file. If the compile attempt fails, only the C# source code will be made available as a client artifact.
The C# XML module is configured with the csharp-xml
element under the modules
element of the enunciate configuration file. The following attributes are supported on the csharp-xml
element:
attribute | description |
---|---|
slug |
The "slug" attribute is the label for the C# XML API. This is the name by which the files will be identified, producing [slug].cs and [slug].dll. By default the slug is the same as the Enunciate project slug. For a more custom configuration of the generated file names, use the "bundleFileName", "DLLFileName", "docXmlFileName", and "sourceFileName" attributes. |
compileExecutable |
The "compileExecutable" attribute is the executable for invoking the C# compiler. If not supplied, an attempt will be made to find a C# compiler on the system path. If the attempt fails, the C# code will not be compiled (but the source code will still be made available as a download artifact). |
compileCommand |
The "compileCommand" is a Java format string that represents the full command that is used to invoke the C# compiler. The string will be formatted with the following arguments: compile executable, assembly path, doc xml path, source doc path. The default value is "%s /target:library /out:%s /r:System.Web.Services /doc:%s %s" |
singleFilePerClass |
The "singleFilePerClass" allows you to specify that Enunciate should generate a file for each C# class. By default (false), Enunciate puts all C# classes into a single file. |
The csharp-xml
element supports the following child elements:
The package-conversions
subelement of the csharp
element is used to map packages from the original API packages to C# namespaces. This element supports an arbitrary number of convert
child elements that are used to specify the conversions. These convert
elements support the following attributes:
- The
from
attribute specifies the package that is to be converted. This package will match all classes in the package as well as any subpackages of the package. This means that if "org.enunciate" were specified, it would match "org.enunciate", "org.enunciate.api", and "org.enunciate.api.impl". - The
to
attribute specifies what the package is to be converted to. Only the part of the package that matches thefrom
attribute will be converted.
Facet configuration for the module. See Facets.