1 package xdoclet.modules.ojb; 2 3 17 18 import xdoclet.DocletTask; 19 import xdoclet.modules.ojb.constraints.ConstraintsBase; 20 21 28 public class OjbDocletTask extends DocletTask 29 { 30 31 private String _checkingLevel = ConstraintsBase.CHECKLEVEL_STRICT; 32 33 public void setChecks(String level) 34 { 35 if (ConstraintsBase.CHECKLEVEL_NONE.equals(level)) 36 { 37 LogHelper.warn(true, 38 OjbDocletTask.class, 39 "setChecks", 40 "Disabling checks. Please use this level only if you have problems with the other check levels. In this case, please post the problem to the ojb-user mailing list."); 41 _checkingLevel = level; 42 } 43 else if (ConstraintsBase.CHECKLEVEL_BASIC.equals(level)) 44 { 45 LogHelper.warn(true, 46 OjbDocletTask.class, 47 "setChecks", 48 "Disabling strict checks."); 49 _checkingLevel = level; 50 } 51 else if (ConstraintsBase.CHECKLEVEL_STRICT.equals(level)) 52 { 53 _checkingLevel = level; 54 } 55 else 56 { 57 LogHelper.warn(true, 58 OjbDocletTask.class, 59 "setChecks", 60 "Unknown checks value: "+level+". Using default level "+ConstraintsBase.CHECKLEVEL_STRICT+" instead."); 61 _checkingLevel = ConstraintsBase.CHECKLEVEL_STRICT; 62 } 63 } 64 65 public String getChecks() 66 { 67 return _checkingLevel; 68 } 69 } 70 | Popular Tags |