1 24 package org.riotfamily.forms.factory; 25 26 import org.springframework.core.io.Resource; 27 28 33 public class FormRepositoryException extends FormDefinitionException { 34 35 private String resourceDescription; 36 37 private String formId; 38 39 40 public FormRepositoryException(String msg) { 41 super(msg); 42 } 43 44 public FormRepositoryException(String msg, Throwable ex) { 45 super(msg, ex); 46 } 47 48 55 public FormRepositoryException(Resource documentLocation, 56 String formId, String msg) { 57 58 this(documentLocation.getDescription(), formId, msg, null); 59 } 60 61 69 public FormRepositoryException(Resource documentLocation, 70 String formId, String msg, Throwable ex) { 71 72 this(documentLocation.getDescription(), formId, msg, ex); 73 } 74 75 82 public FormRepositoryException(String resourceDescription, 83 String formId, String msg) { 84 85 this(resourceDescription, formId, msg, null); 86 } 87 88 96 public FormRepositoryException(String resourceDescription, 97 String formId, String msg, Throwable ex) { 98 99 super("Error registering form with id '" + formId + "' defined in " 100 + resourceDescription + ": " + msg, ex); 101 102 this.resourceDescription = resourceDescription; 103 this.formId = formId; 104 } 105 106 110 public String getResourceDescription() { 111 return resourceDescription; 112 } 113 114 117 public String getFormId() { 118 return formId; 119 } 120 121 } 122 | Popular Tags |