/** * Reads the entire contents of the text file at <code>logfile</code> into a * string using the {@link Charset#defaultCharset() default charset} for * decoding. If no such file exists, an empty string is returned. * @param logfile The text file to read in its entirety. * @return The entire text content of <code>logfile</code>. * @throws IOException If an error occurs while reading the file. * @deprecated call {@link #loadFile(java.io.File, java.nio.charset.Charset)} * instead to specify the charset to use for decoding (preferably * {@link java.nio.charset.StandardCharsets#UTF_8}). */ @Nonnull @Deprecated public static String loadFile(@Nonnull File logfile) throws IOException { return loadFile(logfile, Charset.defaultCharset()); }
/** * Gets the string representation of the agent log. */ public String getLog() throws IOException { return Util.loadFile(getLogFile()); }
public String getLog() throws IOException { return Util.loadFile(getLogFile()); }
/** * Gets the log of the build as a string. * @return Returns the log or an empty string if it has not been found * @deprecated since 2007-11-11. * Use {@link #getLog(int)} instead as it avoids loading * the whole log into memory unnecessarily. */ @Deprecated public @Nonnull String getLog() throws IOException { return Util.loadFile(getLogFile(),getCharset()); }
/** * Loads the contents of a file into a string. */ public static String loadFile(File logfile) throws IOException { return loadFile(logfile, Charset.defaultCharset()); }
/** * Loads the contents of a file into a string. */ public static String loadFile(File logfile) throws IOException { return loadFile(logfile, Charset.defaultCharset()); }
/** * Loads the contents of a file into a string. */ @Nonnull public static String loadFile(@Nonnull File logfile) throws IOException { return loadFile(logfile, Charset.defaultCharset()); }
@SuppressWarnings("unused") public String getLog() throws IOException { File logFile = getLogFile(); if (logFile == null) { return null; } return Util.loadFile(logFile); }
/** * Gets the string representation of the slave log. */ public String getLog() throws IOException { return Util.loadFile(getLogFile()); }
/** * Gets the string representation of the agent log. */ public String getLog() throws IOException { return Util.loadFile(getLogFile()); }
/** * Gets the string representation of the slave log. */ public String getLog() throws IOException { return Util.loadFile(getLogFile()); }
/** * Gets the string representation of the slave log. */ public String getLog() throws IOException { return Util.loadFile(getLogFile()); }
public String getLog() throws IOException { return Util.loadFile(getLogFile()); }
/** * Gets the string representation of the slave log. */ public String getLog() throws IOException { return Util.loadFile(getLogFile()); }
/** * Get log. */ @SuppressWarnings("unused") public String getLog() throws IOException { return Util.loadFile(getLogFile()); }
/** * Gets the log of the build as a string. * @return Returns the log or an empty string if it has not been found * @deprecated since 2007-11-11. * Use {@link #getLog(int)} instead as it avoids loading * the whole log into memory unnecessarily. */ @Deprecated public @Nonnull String getLog() throws IOException { return Util.loadFile(getLogFile(),getCharset()); }
/** * Gets the log of the build as a string. * * @deprecated since 2007-11-11. * Use {@link #getLog(int)} instead as it avoids loading * the whole log into memory unnecessarily. */ @Deprecated public String getLog() throws IOException { return Util.loadFile(getLogFile(),getCharset()); }
/** * Gets the log of the build as a string. * * @deprecated since 2007-11-11. * Use {@link #getLog(int)} instead as it avoids loading * the whole log into memory unnecessarily. */ @Deprecated public String getLog() throws IOException { return Util.loadFile(getLogFile(),getCharset()); }
/** * Get entire log file (this method is deprecated in hudson.model.Run, * but in tests it is OK to load entire log). */ protected static String getLog(Run run) throws IOException { return Util.loadFile(run.getLogFile(), run.getCharset()); }
/** * Get entire log file (this method is deprecated in hudson.model.Run, but * in tests it is OK to load entire log). */ protected static String getLog(Run run) throws IOException { return Util.loadFile(run.getLogFile(), run.getCharset()); }