Skip to content

Commit

Permalink
use typeMapping instead of postProcessParameter (#7457)
Browse files Browse the repository at this point in the history
  • Loading branch information
wing328 authored Sep 21, 2020
1 parent be151fc commit 7fa02ee
Showing 1 changed file with 3 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,9 @@ public JavaVertXWebServerCodegen() {

// Override type mapping
typeMapping.put("file", "FileUpload");
typeMapping.put("UUID", "String");
typeMapping.put("date", "String");
typeMapping.put("DateTime", "String");
}

public CodegenType getTag() {
Expand Down Expand Up @@ -160,14 +163,6 @@ public Map<String, Object> postProcessOperationsWithModels(Map<String, Object> o
return newObjs;
}

@Override
public void postProcessParameter(CodegenParameter parameter) {
super.postProcessParameter(parameter);
if (parameter.isUuid || parameter.isDate || parameter.isDateTime) {
parameter.dataType = "String";
}
}

@Override
public Map<String, Object> postProcessSupportingFileData(Map<String, Object> objs) {
generateYAMLSpecFile(objs);
Expand Down

0 comments on commit 7fa02ee

Please sign in to comment.