Skip to content

Commit

Permalink
moved changes to updated file and the removed miss located one
Browse files Browse the repository at this point in the history
  • Loading branch information
HugoMario committed Jun 6, 2019
1 parent e646f7f commit a7b78bf
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 245 deletions.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.stream.Collectors;
import java.util.stream.Stream;

public class ModelUtils {
/**
Expand Down Expand Up @@ -43,15 +46,18 @@ public static CodegenModel getModelByName(final String name, final Map<String, O
}

public static Operation[] createOperationArray (PathItem pathItem) {
return new Operation[]{
return Stream.of(
pathItem.getGet(),
pathItem.getPost(),
pathItem.getDelete(),
pathItem.getHead(),
pathItem.getPut(),
pathItem.getPatch(),
pathItem.getOptions()
};
)
.filter(Objects::nonNull)
.collect(Collectors.toSet())
.toArray(new Operation[]{});
}

public static void processCodegenModels(Map<String, CodegenModel> allModels) {
Expand Down

0 comments on commit a7b78bf

Please sign in to comment.