File tree Expand file tree Collapse file tree 2 files changed +10
-2
lines changed
swagger-parser-core/src/main/java/io/swagger/v3/parser/core/models
swagger-parser-v3/src/main/java/io/swagger/v3/parser/processors Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ public class ParseOptions {
15
15
private boolean validateInternalRefs = true ;
16
16
private boolean legacyYamlDeserialization = false ;
17
17
private boolean resolveRequestBody = false ;
18
-
18
+ private boolean resolveResponses = false ;
19
19
private boolean oaiAuthor ;
20
20
private boolean inferSchemaType = true ;
21
21
private boolean safelyResolveURL ;
@@ -161,4 +161,12 @@ public List<String> getRemoteRefBlockList() {
161
161
public void setRemoteRefBlockList (List <String > remoteRefBlockList ) {
162
162
this .remoteRefBlockList = remoteRefBlockList ;
163
163
}
164
+
165
+ public boolean isResolveResponses () {
166
+ return resolveResponses ;
167
+ }
168
+
169
+ public void setResolveResponses (boolean resolveResponses ) {
170
+ this .resolveResponses = resolveResponses ;
171
+ }
164
172
}
Original file line number Diff line number Diff line change @@ -71,7 +71,7 @@ public void processOperation(Operation operation) {
71
71
ApiResponse response = responses .get (responseCode );
72
72
if (response != null ) {
73
73
//This part allows parser to put response inline without the resolveFully option set to true
74
- if (response .get$ref () != null ) {
74
+ if (response .get$ref () != null && cache != null && cache . getParseOptions () != null && cache . getParseOptions (). isResolveResponses () ) {
75
75
76
76
responseProcessor .processResponse (response );
77
77
You can’t perform that action at this time.
0 commit comments