@Test public void testGetPaths() { logger.debug("testGetPaths: enter"); try { String logPaths = "C:\\pap-log\\pap-rest.log;C:\\pap-log\\debug.log;C:\\pap-log\\error.log"; String[] retrunObject = ParseLog.getPaths(logPaths); assertEquals(3, retrunObject.length); logPaths = "C:\\pap-log\\pap-rest.log"; retrunObject = ParseLog.getPaths(logPaths); assertEquals(1, retrunObject.length); logPaths = ""; retrunObject = ParseLog.getPaths(logPaths); assertTrue(retrunObject == null); } catch (final Exception e) { fail(); } logger.debug("testGetPaths: exit"); }
public static String[] getPaths(final String logPath) { String[] oneFile = null; if (logPath != null && !logPath.isEmpty()) { if (logPath.contains(";")) { return logPath.split(";"); } else { oneFile = new String[1]; oneFile[0] = logPath; } } return oneFile; }
ParseLog { public static String[] getPaths(final String logPath) { String[] oneFile = null; if (logPath != null && !logPath.isEmpty()) { if (logPath.contains(";")) { return logPath.split(";"); } else { oneFile = new String[1]; oneFile[0] = logPath; } } return oneFile; } }
ParseLog { public static String[] getPaths(final String logPath) { String[] oneFile = null; if (logPath != null && !logPath.isEmpty()) { if (logPath.contains(";")) { return logPath.split(";"); } else { oneFile = new String[1]; oneFile[0] = logPath; } } return oneFile; }  }
ParseLog { public static String[] getPaths(final String logPath) { String[] oneFile = null; if (logPath != null && !logPath.isEmpty()) { if (logPath.contains(";")) { return logPath.split(";"); } else { oneFile = new String[1]; oneFile[0] = logPath; } } return oneFile; }  static void main(final String[] args); static int countLines(final String filename); static String pullLastLineRead(final File file, final String dataFileName); static LogEntryObject pullOutLogValues(final String line, final String type); static void process(final String line, final String type, final LogType logFile); static Date parseDate(final String dateline, final String pattern, final boolean singleSplit); static String parseRemoteSystem(final String line); static String[] getPaths(final String logPath); static Properties getPropertiesValue(final String fileName); static Connection getDbConnection(); }
ParseLog { public static String[] getPaths(final String logPath) { String[] oneFile = null; if (logPath != null && !logPath.isEmpty()) { if (logPath.contains(";")) { return logPath.split(";"); } else { oneFile = new String[1]; oneFile[0] = logPath; } } return oneFile; }  static void main(final String[] args); static int countLines(final String filename); static String pullLastLineRead(final File file, final String dataFileName); static LogEntryObject pullOutLogValues(final String line, final String type); static void process(final String line, final String type, final LogType logFile); static Date parseDate(final String dateline, final String pattern, final boolean singleSplit); static String parseRemoteSystem(final String line); static String[] getPaths(final String logPath); static Properties getPropertiesValue(final String fileName); static Connection getDbConnection();  }