|
15 | 15 | import org.apache.commons.lang3.StringUtils; |
16 | 16 | import org.openapitools.openapidiff.core.exception.RendererException; |
17 | 17 | import org.openapitools.openapidiff.core.model.*; |
| 18 | +import org.openapitools.openapidiff.core.model.schema.ChangedOperationId; |
18 | 19 | import org.openapitools.openapidiff.core.utils.RefPointer; |
19 | 20 | import org.openapitools.openapidiff.core.utils.RefType; |
20 | 21 |
|
@@ -79,6 +80,12 @@ private void ol_changed( |
79 | 80 |
|
80 | 81 | safelyAppend(outputStreamWriter, itemEndpoint(method, pathUrl, desc)); |
81 | 82 |
|
| 83 | + if (result(operation.getOperationId()).isDifferent()) { |
| 84 | + safelyAppend(outputStreamWriter, StringUtils.repeat(' ', 2)); |
| 85 | + safelyAppend(outputStreamWriter, "Operation ID:"); |
| 86 | + safelyAppend(outputStreamWriter, System.lineSeparator()); |
| 87 | + safelyAppend(outputStreamWriter, ul_operation_id(operation.getOperationId())); |
| 88 | + } |
82 | 89 | if (result(operation.getParameters()).isDifferent()) { |
83 | 90 | safelyAppend(outputStreamWriter, StringUtils.repeat(' ', 2)); |
84 | 91 | safelyAppend(outputStreamWriter, "Parameter:"); |
@@ -301,6 +308,10 @@ private String itemEndpoint(String method, String path, String desc) { |
301 | 308 | return String.format("- %s %s%n", StringUtils.rightPad(method, 6), path); |
302 | 309 | } |
303 | 310 |
|
| 311 | + private String ul_operation_id(ChangedOperationId operationId) { |
| 312 | + return String.format(" - Changed %s to %s\n", operationId.getLeft(), operationId.getRight()); |
| 313 | + } |
| 314 | + |
304 | 315 | public String renderBody(String ol_new, String ol_miss, String ol_deprec, String ol_changed) { |
305 | 316 | return ol_new + ol_miss + ol_deprec + ol_changed; |
306 | 317 | } |
|
0 commit comments