Class TranslationStatistics
java.lang.Object
|
+--TranslationStatistics
- class TranslationStatistics
- extends java.lang.Object
- implements java.lang.Runnable, UserOptions
This class computes statstics concerning the performances of the 5 types of translation
- See Also:
UserOptions
Method Summary |
private void |
Calculate()
computes the statistics |
private java.lang.String |
DeleteDotsAndCommas(java.lang.String a_string)
|
private void |
GetTurn(Judgements j)
retrieve the data |
void |
HideDialog()
dismiss the window |
private void |
init()
initialize the data |
private boolean |
isDotOrComma(char a_char)
|
private boolean |
isSelected(java.lang.String segment,
int number)
|
private void |
ParseBest()
|
private void |
ParseChosen(int k)
|
void |
run()
starts the computations |
void |
ShowDialog()
pops-up the window and starts a thread for computations |
void |
Update()
called when a change is done by the user on some criteria or constraints in the user interface |
private void |
UpdateDialog()
updates the view of the table |
Methods inherited from class java.lang.Object |
,
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
registerNatives,
toString,
wait,
wait,
wait |
dialog
javax.swing.JDialog dialog
isShown
boolean isShown
best
java.lang.String best
chosen
java.lang.String chosen
trans
java.lang.String[] trans
best_trans
int[][] best_trans
segments
float[] segments
turns
float[] turns
chosen_segments
float[] chosen_segments
chosen_turns
float[] chosen_turns
best_chosen_segments
float[] best_chosen_segments
best_chosen_turns
float[] best_chosen_turns
mainframe
javax.swing.JFrame mainframe
ui
UserInterface ui
command
java.lang.String command
myModel
javax.swing.table.DefaultTableModel myModel
columnNames
final java.lang.String[] columnNames
data
final java.lang.String[][] data
columns_aux
final java.lang.String[] columns_aux
data_aux
final java.lang.String[] data_aux
TranslationStatistics
TranslationStatistics(javax.swing.JFrame mainframe,
UserInterface ui)
- builts the window and the widgets
HideDialog
public void HideDialog()
- dismiss the window
ShowDialog
public void ShowDialog()
- pops-up the window and starts a thread for computations
- See Also:
UpdateDialog()
Update
public void Update()
- called when a change is done by the user on some criteria or constraints in the user interface
- See Also:
UpdateDialog()
run
public void run()
- starts the computations
- Specified by:
- run in interface java.lang.Runnable
- See Also:
Calculate()
UpdateDialog
private void UpdateDialog()
- updates the view of the table
init
private void init()
- initialize the data
GetTurn
private void GetTurn(Judgements j)
- retrieve the data
- Parameters:
j
- the current turn
Calculate
private void Calculate()
- computes the statistics
- See Also:
ParseChosen(int)
,
ParseBest()
ParseBest
private void ParseBest()
ParseChosen
private void ParseChosen(int k)
isSelected
private boolean isSelected(java.lang.String segment,
int number)
isDotOrComma
private boolean isDotOrComma(char a_char)
DeleteDotsAndCommas
private java.lang.String DeleteDotsAndCommas(java.lang.String a_string)