Zmiany michała

This commit is contained in:
Tomasz Piechucki 2011-04-05 15:02:21 +00:00
parent 2d8ed7ab41
commit 9ded00d0f5
2 changed files with 11 additions and 3 deletions

View file

@ -10,14 +10,18 @@ package winda.logic;
* @author Tomek * @author Tomek
*/ */
public class AlgorytmNajblizszeWezwanie implements IAlgorytm{ public class AlgorytmNajblizszeWezwanie implements IAlgorytm{
int pietroWindy = 1; int pietroWindy = 1;
int maxPietro = 12; int maxPietro;
int minPietro = 1; int minPietro = 1;
int stop = 0; int stop = 0;
int start = 0; int start = 0;
Winda ww = new Winda();
Pasazer p = new Pasazer(0,0,0); Pasazer p = new Pasazer(0,0,0);
public int[] Trasa(Pasazer[] pasazerowie){ public int[] Trasa(Pasazer[] pasazerowie){
maxPietro = ww.GetIloscPieter();
int [] t = new int[2*pasazerowie.length+1]; int [] t = new int[2*pasazerowie.length+1];
int tab_len = 0; int tab_len = 0;
int iluPasazerow = 0; int iluPasazerow = 0;

View file

@ -82,6 +82,10 @@ public class Winda {
CzasSredniObslugi = CzasJazdy / IloscPasazerow; CzasSredniObslugi = CzasJazdy / IloscPasazerow;
} }
public int GetIloscPieter(){
return this.IloscPieter;
}
public static void main(String[] args) { public static void main(String[] args) {
Winda w = new Winda(); Winda w = new Winda();