All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.snapscript.studio.agent.task.ExceptionBuilder Maven / Gradle / Ivy

The newest version!
package org.snapscript.studio.agent.task;

import java.io.PrintWriter;
import java.io.StringWriter;

public class ExceptionBuilder {

   public static String build(Throwable cause) {
      StringWriter buffer = new StringWriter();
      PrintWriter writer = new PrintWriter(buffer);
      
      cause.printStackTrace(writer);
      writer.flush();
      writer.close();
      
      return buffer.toString();
   }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy