1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
| public final List<Integer> fonctionPourOptim() {
List<Integer> locNumberList = new LinkedList<Integer> ();
for (int i = 0; i < 20000; ++i) {
Calendar locCal = new GregorianCalendar ();
locNumberList.add (getNewValue(locCal.get (Calendar.YEAR), i));
}
modifieListe (locNumberList) ;
Double locResult = 0.0 ;
for (int i = 0; i < locNumberList.size(); ++i) {
final Double locTmpValue = faitTraitement (locNumberList.get(i));
if (locTmpValue != null) {
locResult += locTmpValue ;
}
}
stockeResultat(locResult) ;
return locNumberList ;
}
private Integer getNewValue (int parYearValue, int parIndex) {
}
private void modifieListe (List<Integer> parList) {
} // Modifie la liste donnée en paramètre
private double faitTraitement (Integer parValue) {
}
private void stockeResultat (double parValue) {
} // Stocke la valeur dans la classe pour un traitement ultérieur |
Partager