/** * Checks if the path is valid and throws an exception if it's not. * @param path the path to check * @throws ExtensionDataAccessException if the path is not valid */ public static void checkValidPath(String path) throws ExtensionDataAccessException { if (!isValidPath(path)) { throw new ExtensionDataAccessException("Invalid path: " + path); } }
/** * Checks if the path is valid and throws an exception if it's not. * @param path the path to check * @throws DaoException if the path is not valid */ public static void checkValidPath(String path) throws DaoException { if (!isValidPath(path)) { throw new DaoException("Invalid path: " + path); } }