1 25 26 package org.objectweb.easybeans.deployment.annotations.impl; 27 28 import java.lang.annotation.Annotation ; 29 30 import javax.ejb.ApplicationException ; 31 32 36 public class JApplicationException implements ApplicationException { 37 38 41 private boolean rollback = false; 42 43 47 public JApplicationException() { 48 this(false); 49 } 50 51 55 public JApplicationException(final boolean rollback) { 56 this.rollback = rollback; 57 } 58 59 62 public boolean rollback() { 63 return rollback; 64 } 65 66 69 public Class <? extends Annotation > annotationType() { 70 return ApplicationException .class; 71 } 72 73 76 @Override 77 public String toString() { 78 StringBuilder sb = new StringBuilder (); 79 sb.append(this.getClass().getName().substring(this.getClass().getPackage().getName().length() + 1)); 81 sb.append("[rollback="); 83 sb.append(rollback); 84 85 sb.append("]"); 86 return sb.toString(); 87 } 88 } 89 | Popular Tags |