Skip to content

Commit

Permalink
Merge branch 'pintomau-fix-order' into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
bsorrentino committed Oct 12, 2021
2 parents e4f2162 + fd9166b commit 9c1d827
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,7 @@
import java.lang.reflect.Parameter;
import java.lang.reflect.Type;
import java.lang.reflect.TypeVariable;
import java.util.Arrays;
import java.util.Map;
import java.util.Objects;
import java.util.Optional;
import java.util.*;
import java.util.function.Consumer;
import java.util.function.Function;
import java.util.stream.Collectors;
Expand Down Expand Up @@ -97,7 +94,7 @@ public String processStatic(TSType type, java.util.Map<String, TSType> declaredT

if (!methodSet.isEmpty()) {

methodSet.stream().sorted((a, b) -> a.getName().compareTo(b.getName())).forEach(md -> ctx.append('\t')
methodSet.stream().sorted(Comparator.comparing(Method::toGenericString)).forEach(md -> ctx.append('\t')
.append(md.getName()).append(getMethodParametersAndReturnDecl(ctx, md, false)).append(ENDL));
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -151,13 +151,15 @@ public boolean process(Context processingContext) throws Exception {
types.stream()
.filter(tt -> !PREDEFINED_TYPES.contains(tt))
.map(tt -> converter.processClass(0, tt, declaredTypes))
.sorted()
.forEach(wD_append);

wT_append.accept(String.format("/// <reference path=\"%s\"/>\n\n", definitionsFile));

types.stream()
.filter(t -> t.isExport())
.map(t -> converter.processStatic(t, declaredTypes))
.sorted()
.forEach(wT_append);

} // end try-with-resources
Expand Down

0 comments on commit 9c1d827

Please sign in to comment.