1 19 package org.netbeans.modules.refactoring.api; 20 21 22 28 public final class Problem { 29 private final boolean fatal; 30 private final String message; 31 private Problem next = null; 32 private ProblemDetails details; 33 34 38 public Problem(boolean fatal, String message) { 39 this.fatal = fatal; 40 this.message = message; 41 } 42 43 49 public Problem(boolean fatal, String message, ProblemDetails details) { 50 this(fatal, message); 51 this.details = details; 52 } 53 54 57 public boolean isFatal() { 58 return fatal; 59 } 60 61 64 public String getMessage() { 65 return message; 66 } 67 68 71 public Problem getNext() { 72 return next; 73 } 74 75 81 public void setNext(Problem next) throws IllegalStateException { 82 if (this.next != null) { 83 throw new IllegalStateException ("Cannot change \"next\" property of Problem."); } 85 this.next = next; 86 } 87 88 92 public ProblemDetails getDetails() { 93 return details; 94 } 95 } 96 | Popular Tags |