Changeset 15590 in josm for trunk/src/org/openstreetmap
- Timestamp:
- 2019-12-13T23:03:18+01:00 (5 years ago)
- Location:
- trunk/src/org/openstreetmap/josm/tools
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/tools/ImageProvider.java
r15416 r15590 1709 1709 } 1710 1710 1711 ImageInputStream stream = createImageInputStream(input); 1711 ImageInputStream stream = createImageInputStream(input); // NOPMD 1712 1712 if (stream == null) { 1713 1713 throw new IIOException("Can't create an ImageInputStream!"); … … 1759 1759 CheckParameterUtil.ensureParameterNotNull(input, "input"); 1760 1760 1761 ImageInputStream stream = createImageInputStream(input); 1761 ImageInputStream stream = createImageInputStream(input); // NOPMD 1762 1762 BufferedImage bi = read(stream, readMetadata, enforceTransparency); 1763 1763 if (bi == null) { … … 1803 1803 1804 1804 try (InputStream istream = Utils.openStream(input)) { 1805 ImageInputStream stream = createImageInputStream(istream); 1805 ImageInputStream stream = createImageInputStream(istream); // NOPMD 1806 1806 BufferedImage bi = read(stream, readMetadata, enforceTransparency); 1807 1807 if (bi == null) { … … 1854 1854 reader.setInput(stream, true, !readMetadata && !enforceTransparency); 1855 1855 BufferedImage bi = null; 1856 try { 1856 try { // NOPMD 1857 1857 bi = reader.read(0, param); 1858 1858 if (bi.getTransparency() != Transparency.TRANSLUCENT && (readMetadata || enforceTransparency) && Utils.getJavaVersion() < 11) { -
trunk/src/org/openstreetmap/josm/tools/Logging.java
r14302 r15590 95 95 */ 96 96 public synchronized void reacquireOutputStream() { 97 final OutputStream reacquiredStream = this.outputStreamSupplier.get(); 97 final OutputStream reacquiredStream = this.outputStreamSupplier.get(); // NOPMD 98 98 99 99 // only bother calling setOutputStream if it's actually different, as setOutputStream -
trunk/src/org/openstreetmap/josm/tools/PlatformHookWindows.java
r15543 r15590 440 440 File cachePath = Config.getDirs().getCacheDirectory(true); 441 441 Path fontconfigFile = cachePath.toPath().resolve("fontconfig.properties"); 442 OutputStream os = Files.newOutputStream(fontconfigFile); 442 OutputStream os = Files.newOutputStream(fontconfigFile); // NOPMD 443 443 os.write(content); 444 444 try (Writer w = new BufferedWriter(new OutputStreamWriter(os, StandardCharsets.UTF_8))) { -
trunk/src/org/openstreetmap/josm/tools/Utils.java
r15543 r15590 1470 1470 */ 1471 1471 public static byte[] readBytesFromStream(InputStream stream) throws IOException { 1472 // TODO: remove this method when switching to Java 11 and use InputStream.readAllBytes 1472 1473 if (stream == null) { 1473 1474 return new byte[0]; 1474 1475 } 1475 try { 1476 try { // NOPMD 1476 1477 ByteArrayOutputStream bout = new ByteArrayOutputStream(stream.available()); 1477 1478 byte[] buffer = new byte[8192];
Note:
See TracChangeset
for help on using the changeset viewer.