Changeset 15720 in josm for trunk


Ignore:
Timestamp:
2020-01-18T15:02:06+01:00 (5 years ago)
Author:
simon04
Message:

Java 8: use String.join

Location:
trunk/src/org/openstreetmap/josm/io/remotecontrol
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/io/remotecontrol/RequestProcessor.java

    r15588 r15720  
    494494            }
    495495            if (mandatory != null && mandatory.length > 0) {
    496                 usage.append("<br/>mandatory parameters: ").append(Utils.join(", ", Arrays.asList(mandatory)));
     496                usage.append("<br/>mandatory parameters: ").append(String.join(", ", mandatory))
    497497            }
    498498            if (optional != null && optional.length > 0) {
    499                 usage.append("<br/>optional parameters: ").append(Utils.join(", ", Arrays.asList(optional)));
     499                usage.append("<br/>optional parameters: ").append(String.join(", ", optional));
    500500            }
    501501            if (examples != null && examples.length > 0) {
  • trunk/src/org/openstreetmap/josm/io/remotecontrol/handler/ImageryHandler.java

    r14214 r15720  
    131131    @Override
    132132    public String[] getUsageExamples() {
    133         final String types = Utils.join("|", Utils.transform(Arrays.asList(ImageryInfo.ImageryType.values()),
     133        final String types = String.join("|", Utils.transform(Arrays.asList(ImageryInfo.ImageryType.values()),
    134134                ImageryType::getTypeString));
    135135        return new String[] {
  • trunk/src/org/openstreetmap/josm/io/remotecontrol/handler/RequestHandler.java

    r15586 r15720  
    279279            throw new RequestHandlerBadRequestException(
    280280                    tr("The following keys are mandatory, but have not been provided: {0}",
    281                             Utils.join(", ", missingKeys)));
     281                            String.join(", ", missingKeys)));
    282282        }
    283283    }
Note: See TracChangeset for help on using the changeset viewer.