File tree Expand file tree Collapse file tree 2 files changed +30
-0
lines changed
modules/swagger-codegen/src/main/java/io/swagger/codegen/v3 Expand file tree Collapse file tree 2 files changed +30
-0
lines changed Original file line number Diff line number Diff line change @@ -42,6 +42,7 @@ public class CodegenModel extends CodegenObject {
42
42
43
43
public Set <String > imports = new TreeSet <String >();
44
44
public boolean emptyVars ;
45
+ public boolean isComposedModel ;
45
46
public ExternalDocumentation externalDocumentation ;
46
47
47
48
//The type of the value from additional properties. Used in map like objects.
@@ -471,4 +472,12 @@ public String getAdditionalPropertiesType() {
471
472
public void setAdditionalPropertiesType (String additionalPropertiesType ) {
472
473
this .additionalPropertiesType = additionalPropertiesType ;
473
474
}
475
+
476
+ public boolean getIsComposedModel () {
477
+ return isComposedModel ;
478
+ }
479
+
480
+ public void setIsComposedModel (boolean isComposedModel ) {
481
+ this .isComposedModel = isComposedModel ;
482
+ }
474
483
}
Original file line number Diff line number Diff line change
1
+ package io .swagger .codegen .v3 ;
2
+
3
+ import io .swagger .v3 .oas .models .media .Schema ;
4
+
5
+ import java .util .List ;
6
+
7
+ public interface ISchemaHandler {
8
+
9
+ /**
10
+ * check if there is any composed schema in models or properties. And create codegen model objects if it's required.
11
+ * @param codegenModel
12
+ * @param schema
13
+ */
14
+ void proccessComposedSchemas (CodegenModel codegenModel , Schema schema );
15
+
16
+ /**
17
+ * retrieve a list of codegen models created from composed schemas found.
18
+ * @return
19
+ */
20
+ List <CodegenModel > getModels ();
21
+ }
You can’t perform that action at this time.
0 commit comments