View Javadoc

1   /*
2    * joey and its relative products are published under the terms
3    * of the Apache Software License.
4    * 
5    * Created on 2004/06/09 11:27:05
6    */
7   package org.asyrinx.joey.om;
8   
9   import java.io.Serializable;
10  import java.util.List;
11  
12  /***
13   * @author akima
14   */
15  public class EntityServiceWrapper implements EntityService {
16  
17  	/***
18  	 * 
19  	 */
20  	public EntityServiceWrapper(EntityService wrapped) {
21  		super();
22  		this.wrapped = wrapped;
23  	}
24  
25  	protected final EntityService wrapped;
26  	
27  	/* (non-Javadoc)
28  	 * @see org.asyrinx.joey.om.EntityService#newEntity()
29  	 */
30  	public Entity newEntity() {
31  		return wrapped.newEntity();
32  	}
33  
34  	/* (non-Javadoc)
35  	 * @see org.asyrinx.joey.om.EntityService#restoreBeforeSave(org.asyrinx.joey.om.Entity)
36  	 */
37  	public void restoreBeforeSave(Entity entity) {
38  		wrapped.restoreBeforeSave(entity);
39  	}
40  
41  	/***
42  	 * @param key
43  	 */
44  	public void deleteEntity(Serializable key) {
45  		wrapped.deleteEntity(key);
46  	}
47  
48  	/***
49  	 * @param key
50  	 * @return
51  	 */
52  	public Entity loadEntity(Serializable key) {
53  		return wrapped.loadEntity(key);
54  	}
55  
56  	/***
57  	 * @param entity
58  	 */
59  	public void saveEntity(Object entity) {
60  		wrapped.saveEntity(entity);
61  	}
62  
63  	/***
64  	 * @param condition
65  	 * @return
66  	 */
67  	public List select(SearchCondition condition) {
68  		return wrapped.select(condition);
69  	}
70  
71  }