01: // Copyright (c) 2003-2007, Jodd Team (jodd.sf.net). All Rights Reserved.
02:
03: package madvoc.girl;
04:
05: import jodd.petite.meta.PetiteBean;
06: import jodd.petite.scope.SessionScope;
07:
08: import java.util.ArrayList;
09: import java.util.List;
10:
11: /**
12: * Scoped person manager.
13: */
14: @PetiteBean(scope=SessionScope.class)
15: public class GirlManager {
16:
17: private int idCount;
18:
19: private List<Girl> girls = new ArrayList<Girl>();
20:
21: public void add(Girl girl) {
22: girl.setId(idCount++);
23: girls.add(girl);
24: }
25:
26: public List<Girl> getAllGirls() {
27: return girls;
28: }
29: }
|