Skip to content

Commit

Permalink
Add missing @Nullable annotations
Browse files Browse the repository at this point in the history
  • Loading branch information
NebelNidas committed Jan 7, 2025
1 parent ed6b546 commit 7fa68e3
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public MappingNsCompleter(MappingVisitor next) {
* @param alternatives A map of which namespaces should copy from which others.
* Passing {@code null} causes all destination namespaces to be completed.
*/
public MappingNsCompleter(MappingVisitor next, Map<String, String> alternatives) {
public MappingNsCompleter(MappingVisitor next, @Nullable Map<String, String> alternatives) {
this(next, alternatives, false);
}

Expand All @@ -59,7 +59,7 @@ public MappingNsCompleter(MappingVisitor next, Map<String, String> alternatives)
* Passing {@code null} causes all destination namespaces to be completed.
* @param addMissingNs Whether to copy namespaces from the alternatives key set if not already present.
*/
public MappingNsCompleter(MappingVisitor next, Map<String, String> alternatives, boolean addMissingNs) {
public MappingNsCompleter(MappingVisitor next, @Nullable Map<String, String> alternatives, boolean addMissingNs) {
super(next);

this.alternatives = alternatives;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,10 +57,12 @@ public OuterClassNamePropagator(MappingVisitor next) {
}

/**
* @param namespaces The destination namespaces where outer class names shall be propagated.
* Constructs a new {@link OuterClassNamePropagator} which processes the selected destination namespaces.
*
* @param namespaces The destination namespaces where outer class names shall be propagated. Pass {@code null} to process all destination namespaces.
* @param processRemappedDstNames Whether already remapped destination names should also get their unmapped outer classes replaced.
*/
public OuterClassNamePropagator(MappingVisitor next, Collection<String> namespaces, boolean processRemappedDstNames) {
public OuterClassNamePropagator(MappingVisitor next, @Nullable Collection<String> namespaces, boolean processRemappedDstNames) {
super(next);
this.dstNamespacesToProcess = namespaces;
this.processRemappedDstNames = processRemappedDstNames;
Expand Down Expand Up @@ -257,6 +259,8 @@ public boolean visitEnd() throws IOException {
private final boolean processRemappedDstNames;
private final Map<String, String[]> dstNamesBySrcName = new HashMap<>();
private final Set<String> modifiedClasses = new HashSet<>();
private String srcNamespaceToProcess;
private int srcNsId;
private List<String> dstNamespaces;
private Collection<String> dstNamespacesToProcess;
private Collection<Integer> dstNamespaceIndicesToProcess;
Expand Down

0 comments on commit 7fa68e3

Please sign in to comment.