Merge pull request #1628 from wing328/csharp_optional_parameter

[C#] add optional parameter to c# API client
This commit is contained in:
wing328
2015-11-30 00:09:25 +08:00
14 changed files with 86 additions and 63 deletions

View File

@@ -27,6 +27,8 @@ public class CSharpClientOptionsTest extends AbstractOptionsTest {
new Expectations(clientCodegen) {{
clientCodegen.setPackageName(CSharpClientOptionsProvider.PACKAGE_NAME_VALUE);
times = 1;
clientCodegen.setOptionalMethodArgumentFlag(true);
times = 1;
clientCodegen.setPackageVersion(CSharpClientOptionsProvider.PACKAGE_VERSION_VALUE);
times = 1;
}};

View File

@@ -21,6 +21,7 @@ public class CSharpClientOptionsProvider implements OptionsProvider {
return builder.put(CodegenConstants.PACKAGE_NAME, PACKAGE_NAME_VALUE)
.put(CodegenConstants.PACKAGE_VERSION, PACKAGE_VERSION_VALUE)
.put(CodegenConstants.SORT_PARAMS_BY_REQUIRED_FLAG, "true")
.put(CodegenConstants.OPTIONAL_METHOD_ARGUMENT, "true")
.build();
}