Here you can find the source of exist(Path... paths)
Helper method to check Path existence.
Parameter | Description |
---|---|
paths | a parameter |
protected static boolean exist(Path... paths)
//package com.java2s; /*/* w w w .j a v a 2 s. c o m*/ * Copyright (C) 2017 Nameless Production Committee * * Licensed under the MIT License (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * https://opensource.org/licenses/MIT */ import java.nio.file.Files; import java.nio.file.Path; public class Main { /** * <p> * Helper method to check {@link Path} existence. * </p> * * @param paths * @return */ protected static boolean exist(Path... paths) { for (Path path : paths) { assert Files.exists(path); } return true; } }