1 package org.hibernate; 3 4 import java.io.Serializable ; 5 import java.math.BigDecimal ; 6 import java.math.BigInteger ; 7 import java.util.Calendar ; 8 import java.util.Collection ; 9 import java.util.Date ; 10 import java.util.Iterator ; 11 import java.util.List ; 12 import java.util.Locale ; 13 14 import org.hibernate.type.Type; 15 16 55 public interface Query { 56 61 public String getQueryString(); 62 66 public Type[] getReturnTypes() throws HibernateException; 67 71 public String [] getReturnAliases() throws HibernateException; 72 76 public String [] getNamedParameters() throws HibernateException; 77 88 public Iterator iterate() throws HibernateException; 89 98 public ScrollableResults scroll() throws HibernateException; 99 109 public ScrollableResults scroll(ScrollMode scrollMode) throws HibernateException; 110 118 public List list() throws HibernateException; 119 126 public Object uniqueResult() throws HibernateException; 127 128 137 public int executeUpdate() throws HibernateException; 138 139 144 public Query setMaxResults(int maxResults); 145 150 public Query setFirstResult(int firstResult); 151 152 159 public Query setReadOnly(boolean readOnly); 160 161 165 public Query setCacheable(boolean cacheable); 166 167 172 public Query setCacheRegion(String cacheRegion); 173 174 178 public Query setTimeout(int timeout); 179 183 public Query setFetchSize(int fetchSize); 184 185 190 public Query setLockMode(String alias, LockMode lockMode); 191 192 196 public Query setComment(String comment); 197 198 203 public Query setFlushMode(FlushMode flushMode); 204 205 210 public Query setCacheMode(CacheMode cacheMode); 211 212 219 public Query setParameter(int position, Object val, Type type); 220 226 public Query setParameter(String name, Object val, Type type); 227 228 236 public Query setParameter(int position, Object val) throws HibernateException; 237 244 public Query setParameter(String name, Object val) throws HibernateException; 245 246 249 public Query setParameters(Object [] values, Type[] types) throws HibernateException; 250 251 258 public Query setParameterList(String name, Collection vals, Type type) throws HibernateException; 259 260 267 public Query setParameterList(String name, Collection vals) throws HibernateException; 268 269 276 public Query setParameterList(String name, Object [] vals, Type type) throws HibernateException; 277 278 285 public Query setParameterList(String name, Object [] vals) throws HibernateException; 286 287 293 public Query setProperties(Object bean) throws HibernateException; 294 295 public Query setString(int position, String val); 296 public Query setCharacter(int position, char val); 297 public Query setBoolean(int position, boolean val); 298 public Query setByte(int position, byte val); 299 public Query setShort(int position, short val); 300 public Query setInteger(int position, int val); 301 public Query setLong(int position, long val); 302 public Query setFloat(int position, float val); 303 public Query setDouble(int position, double val); 304 public Query setBinary(int position, byte[] val); 305 public Query setText(int position, String val); 306 public Query setSerializable(int position, Serializable val); 307 public Query setLocale(int position, Locale locale); 308 public Query setBigDecimal(int position, BigDecimal number); 309 public Query setBigInteger(int position, BigInteger number); 310 311 public Query setDate(int position, Date date); 312 public Query setTime(int position, Date date); 313 public Query setTimestamp(int position, Date date); 314 315 public Query setCalendar(int position, Calendar calendar); 316 public Query setCalendarDate(int position, Calendar calendar); 317 318 public Query setString(String name, String val); 319 public Query setCharacter(String name, char val); 320 public Query setBoolean(String name, boolean val); 321 public Query setByte(String name, byte val); 322 public Query setShort(String name, short val); 323 public Query setInteger(String name, int val); 324 public Query setLong(String name, long val); 325 public Query setFloat(String name, float val); 326 public Query setDouble(String name, double val); 327 public Query setBinary(String name, byte[] val); 328 public Query setText(String name, String val); 329 public Query setSerializable(String name, Serializable val); 330 public Query setLocale(String name, Locale locale); 331 public Query setBigDecimal(String name, BigDecimal number); 332 public Query setBigInteger(String name, BigInteger number); 333 334 public Query setDate(String name, Date date); 335 public Query setTime(String name, Date date); 336 public Query setTimestamp(String name, Date date); 337 338 public Query setCalendar(String name, Calendar calendar); 339 public Query setCalendarDate(String name, Calendar calendar); 340 341 347 public Query setEntity(int position, Object val); 349 354 public Query setEntity(String name, Object val); 356 } 357 358 359 360 361 362 363 364 | Popular Tags |