diff options
author | vasraz <vasyl.razinkov@est.tech> | 2021-03-22 15:33:06 +0000 |
---|---|---|
committer | Christophe Closset <christophe.closset@intl.att.com> | 2021-03-24 06:59:47 +0000 |
commit | d378c37fbd1ecec7b43394926f1ca32a695e07de (patch) | |
tree | 5c8a085f8732f980d871d966ac49361644efa698 /openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/file/FileContentHandler.java | |
parent | a6ae7294ecd336d7e88f915710b08e2658eaee00 (diff) |
Reformat openecomp-be
Signed-off-by: Vasyl Razinkov <vasyl.razinkov@est.tech>
Issue-ID: SDC-3449
Change-Id: I13e02322f8e00820cc5a1d85752caaeda9bf10d1
Diffstat (limited to 'openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/file/FileContentHandler.java')
-rw-r--r-- | openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/file/FileContentHandler.java | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/file/FileContentHandler.java b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/file/FileContentHandler.java index 2a3a3bd19e..89f1f3a293 100644 --- a/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/file/FileContentHandler.java +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/file/FileContentHandler.java @@ -17,7 +17,6 @@ * limitations under the License. * ============LICENSE_END========================================================= */ - package org.openecomp.core.utilities.file; import java.io.ByteArrayInputStream; @@ -54,7 +53,6 @@ public class FileContentHandler { if (content == null || content.length == 0) { return null; } - return new ByteArrayInputStream(content); } @@ -101,7 +99,7 @@ public class FileContentHandler { * Adds a file. * * @param filePath the file path - * @param content the file content + * @param content the file content */ public void addFile(final String filePath, final byte[] content) { files.put(filePath, content == null ? new byte[0] : content); @@ -110,7 +108,7 @@ public class FileContentHandler { /** * Adds a file. * - * @param filePath the file path + * @param filePath the file path * @param fileInputStream the file input stream */ public void addFile(final String filePath, final InputStream fileInputStream) { @@ -123,8 +121,7 @@ public class FileContentHandler { * @return a file path:content map */ public Map<String, byte[]> getFiles() { - return files.entrySet().stream().filter(entry -> entry.getValue() != null) - .collect(Collectors.toMap(Map.Entry::getKey, Map.Entry::getValue)); + return files.entrySet().stream().filter(entry -> entry.getValue() != null).collect(Collectors.toMap(Map.Entry::getKey, Map.Entry::getValue)); } public void setFiles(final Map<String, byte[]> files) { @@ -190,5 +187,4 @@ public class FileContentHandler { public boolean containsFile(final String filePath) { return files.containsKey(filePath); } - } |