Class BacktraceReport

java.lang.Object
backtraceio.library.models.json.BacktraceReport

public class BacktraceReport extends Object
Captured application error
  • Field Details

    • uuid

      public UUID uuid
      16 bytes of randomness in human readable UUID format server will reject request if uuid is already found
    • timestamp

      public long timestamp
      UTC timestamp in seconds
    • exceptionTypeReport

      public Boolean exceptionTypeReport
      Get information about report type. If value is true the BacktraceReport has an error
    • classifier

      public String classifier
      Get a report classification
    • attributes

      public Map<String,Object> attributes
      Get an report attributes
    • message

      public String message
      Get a custom client message
    • exception

      public Exception exception
      Get a report exception
    • attachmentPaths

      public List<String> attachmentPaths
      Get all paths to attachments
    • diagnosticStack

      public ArrayList<BacktraceStackFrame> diagnosticStack
      Current report exception stack
  • Constructor Details

    • BacktraceReport

      public BacktraceReport(String message)
      Create new instance of Backtrace report to send a report with custom client message
      Parameters:
      message - custom client message
    • BacktraceReport

      public BacktraceReport(String message, Map<String,Object> attributes)
      Create new instance of Backtrace report to send a report with custom client message and attributes
      Parameters:
      message - custom client message
      attributes - additional information about application state
    • BacktraceReport

      public BacktraceReport(String message, List<String> attachmentPaths)
      Create new instance of Backtrace report to send a report with custom client message, attributes and attachments
      Parameters:
      message - custom client message
      attachmentPaths - path to all report attachments
    • BacktraceReport

      public BacktraceReport(String message, Map<String,Object> attributes, List<String> attachmentPaths)
      Create new instance of Backtrace report to send a report with custom client message, attributes and attachments
      Parameters:
      message - custom client message
      attributes - additional information about application state
      attachmentPaths - path to all report attachments
    • BacktraceReport

      public BacktraceReport(Exception exception)
      Create new instance of Backtrace report to send a report with application exception
      Parameters:
      exception - current exception
    • BacktraceReport

      public BacktraceReport(Exception exception, Map<String,Object> attributes)
      Create new instance of Backtrace report to send a report with application exception and attributes
      Parameters:
      exception - current exception
      attributes - additional information about application state
    • BacktraceReport

      public BacktraceReport(Exception exception, List<String> attachmentPaths)
      Create new instance of Backtrace report to send a report with application exception, attributes and attachments
      Parameters:
      exception - current exception
      attachmentPaths - path to all report attachments
    • BacktraceReport

      public BacktraceReport(Exception exception, Map<String,Object> attributes, List<String> attachmentPaths)
      Create new instance of Backtrace report to send a report with application exception, attributes and attachments
      Parameters:
      exception - current exception
      attributes - additional information about application state
      attachmentPaths - path to all report attachments
  • Method Details

    • getExceptionClassifier

      public String getExceptionClassifier(Exception exception)
    • concatAttributes

      public static Map<String,Object> concatAttributes(BacktraceReport report, Map<String,Object> attributes)
      Concat two dictionaries with attributes
      Parameters:
      report - current report
      attributes - attributes to concatenate
      Returns:
      concatenated map of attributes from report and from passed attributes
    • toBacktraceData

      public BacktraceData toBacktraceData(android.content.Context context, Map<String,Object> clientAttributes)
    • toBacktraceData

      public BacktraceData toBacktraceData(android.content.Context context, Map<String,Object> clientAttributes, boolean isProguardEnabled)