1 2 3 package org.tigris.scarab.om; 4 5 import java.math.BigDecimal ; 6 import java.util.Date ; 7 import java.util.List ; 8 9 import org.apache.torque.Torque; 10 import org.apache.torque.TorqueException; 11 import org.apache.torque.manager.AbstractBaseManager; 12 import org.apache.torque.manager.CacheListener; 13 import org.apache.torque.manager.MethodResultCache; 14 import org.apache.torque.om.ObjectKey; 15 import org.apache.torque.om.SimpleKey; 16 import org.apache.torque.om.Persistent; 17 import org.apache.torque.util.Criteria; 18 19 25 public abstract class BaseRModuleIssueTypeManager 26 extends AbstractBaseManager 27 { 28 29 protected static String MANAGED_CLASS = "org.tigris.scarab.om.RModuleIssueType"; 30 31 32 protected static String DEFAULT_MANAGER_CLASS 33 = "org.tigris.scarab.om.RModuleIssueTypeManager"; 34 35 41 public static RModuleIssueTypeManager getManager() 42 { 43 return (RModuleIssueTypeManager) 44 Torque.getManager(RModuleIssueTypeManager.MANAGED_CLASS, 45 RModuleIssueTypeManager.DEFAULT_MANAGER_CLASS); 46 } 47 48 54 public static RModuleIssueType getInstance() 55 throws TorqueException 56 { 57 return getManager().getInstanceImpl(); 58 } 59 60 67 public static RModuleIssueType getInstance(ObjectKey id) 68 throws TorqueException 69 { 70 return getManager().getInstanceImpl(id); 71 } 72 73 82 public static RModuleIssueType getInstance(ObjectKey id, boolean fromCache) 83 throws TorqueException 84 { 85 return getManager().getInstanceImpl(id, fromCache); 86 } 87 88 89 96 public static List getInstances(List ids) 97 throws TorqueException 98 { 99 return getManager().getInstancesImpl(ids); 100 } 101 102 111 public static List getInstances(List ids, boolean fromCache) 112 throws TorqueException 113 { 114 return getManager().getInstancesImpl(ids, fromCache); 115 } 116 117 public static void putInstance(Persistent om) 118 throws TorqueException 119 { 120 getManager().putInstanceImpl(om); 121 } 122 123 public static void clear() 124 throws TorqueException 125 { 126 getManager().clearImpl(); 127 } 128 129 public static boolean exists(RModuleIssueType obj) 130 throws TorqueException 131 { 132 return getManager().existsImpl(obj); 133 } 134 135 public static MethodResultCache getMethodResult() 136 { 137 return getManager().getMethodResultCache(); 138 } 139 140 public static void addCacheListener(CacheListener listener) 141 { 142 getManager().addCacheListenerImpl(listener); 143 } 144 145 150 public BaseRModuleIssueTypeManager() 151 throws TorqueException 152 { 153 setClassName("org.tigris.scarab.om.RModuleIssueType"); 154 } 155 156 159 protected RModuleIssueType getInstanceImpl() 160 throws TorqueException 161 { 162 RModuleIssueType obj = null; 163 try 164 { 165 obj = (RModuleIssueType) getOMInstance(); 166 } 167 catch (Exception e) 168 { 169 throw new TorqueException(e); 170 } 171 return obj; 172 } 173 174 175 180 protected RModuleIssueType getInstanceImpl(ObjectKey id) 181 throws TorqueException 182 { 183 return (RModuleIssueType) getOMInstance(id); 184 } 185 186 193 protected RModuleIssueType getInstanceImpl(ObjectKey id, boolean fromCache) 194 throws TorqueException 195 { 196 return (RModuleIssueType) getOMInstance(id, fromCache); 197 } 198 199 206 protected List getInstancesImpl(List ids) 207 throws TorqueException 208 { 209 return getOMs(ids); 210 } 211 212 221 protected List getInstancesImpl(List ids, boolean fromCache) 222 throws TorqueException 223 { 224 return getOMs(ids, fromCache); 225 } 226 227 230 protected boolean existsImpl(RModuleIssueType om) 231 throws TorqueException 232 { 233 Criteria crit = RModuleIssueTypePeer 234 .buildCriteria((RModuleIssueType)om); 235 return RModuleIssueTypePeer.doSelect(crit).size() > 0; 236 } 237 238 239 protected Persistent retrieveStoredOM(ObjectKey id) 240 throws TorqueException 241 { 242 return RModuleIssueTypePeer.retrieveByPK(id); 243 } 244 245 252 protected List retrieveStoredOMs(List ids) 253 throws TorqueException 254 { 255 return RModuleIssueTypePeer.retrieveByPKs(ids); 256 } 257 } 258 | Popular Tags |