de.heineken.studienarbeit

Class Loesung


public class Loesung
extends java.lang.Thread

Shows the solution with the currently selected combination of algorithm and buffer size. A thread is needed, because if not used, a stop from the user's side wouldn´t be possible at all.

Field Summary

(package private) int
anfangswert
(package private) Applet1
applet1
(package private) int[]
ausgabewerte
(package private) int[]
eingabewerte
boolean
mayRun
boolean
terminated

Constructor Summary

Loesung(Applet1 applet1, int[] eingabewerte, int[] ausgabewerte, int anfangswert)
Constructor

Method Summary

void
reset()
Sending back and using the object again is possible after a run of this Loesung
void
run()
Solution is shown on the GUI
void
setpfeil(int erste, int zweite)
The method sets the arrow in the solution properly current position in "erste" new position in parameter "zweite"

Field Details

anfangswert

(package private)  int anfangswert

applet1

(package private)  Applet1 applet1

ausgabewerte

(package private)  int[] ausgabewerte

eingabewerte

(package private)  int[] eingabewerte

mayRun

public boolean mayRun

terminated

public boolean terminated

Constructor Details

Loesung

public Loesung(Applet1 applet1,
               int[] eingabewerte,
               int[] ausgabewerte,
               int anfangswert)
Constructor
Parameters:

Method Details

reset

public void reset()
Sending back and using the object again is possible after a run of this Loesung

run

public void run()
Solution is shown on the GUI

setpfeil

public void setpfeil(int erste,
                     int zweite)
The method sets the arrow in the solution properly current position in "erste" new position in parameter "zweite"
Parameters:
erste - current position of the head
zweite - next or new position of the head