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

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

package org.snapscript.studio.agent;

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

public class ExceptionBuilder {

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




© 2015 - 2024 Weber Informatics LLC | Privacy Policy