01: /*
02:
03: This software is OSI Certified Open Source Software.
04: OSI Certified is a certification mark of the Open Source Initiative.
05:
06: The license (Mozilla version 1.0) can be read at the MMBase site.
07: See http://www.MMBase.org/license
08:
09: */
10:
11: package org.mmbase.bridge.implementation;
12:
13: import java.util.Collection;
14:
15: import org.mmbase.bridge.*;
16:
17: /**
18: * A list of relation managers
19: *
20: * @author Pierre van Rooden
21: * @version $Id: BasicRelationManagerList.java,v 1.16 2007/02/10 15:47:42 nklasens Exp $
22: */
23: public class BasicRelationManagerList extends
24: AbstractNodeList<RelationManager> implements
25: RelationManagerList {
26:
27: BasicRelationManagerList() {
28: super ();
29: }
30:
31: BasicRelationManagerList(Collection c, Cloud cloud) {
32: super (c, cloud);
33: }
34:
35: public RelationManager getRelationManager(int index) {
36: return get(index);
37: }
38:
39: public RelationManagerIterator relationManagerIterator() {
40: return new BasicRelationManagerIterator();
41: }
42:
43: public RelationManagerList subRelationManagerList(int fromIndex,
44: int toIndex) {
45: return new BasicRelationManagerList(
46: subList(fromIndex, toIndex), cloud);
47: }
48:
49: protected class BasicRelationManagerIterator extends BasicIterator
50: implements RelationManagerIterator {
51:
52: public RelationManager nextRelationManager() {
53: return next();
54: }
55:
56: public RelationManager previousRelationManager() {
57: return previous();
58: }
59: }
60:
61: }
|