/** Constructor for FiniteList * @param repType the Class which is repeating * @param underlyingObject the underlying object that the extending class represents */ public FiniteList(Class<? extends Repeatable> repType, Object underlyingObject) { this.repType = repType; this.underlyingObject = underlyingObject; Repeatable firstRep = createRep(0); this.maxReps = firstRep.getMaxReps(); // this.minReps = firstRep.getMinReps(); reps = new ArrayList<Repeatable>(); reps.add(firstRep); createNewReps(maxReps); }
/** Constructor for FiniteList * @param repType the Class which is repeating * @param underlyingObject the underlying object that the extending class represents */ public FiniteList(Class<? extends Repeatable> repType, Object underlyingObject) { this.repType = repType; this.underlyingObject = underlyingObject; Repeatable firstRep = createRep(0); this.maxReps = firstRep.getMaxReps(); // this.minReps = firstRep.getMinReps(); reps = new ArrayList<Repeatable>(); reps.add(firstRep); createNewReps(maxReps); }