+ * BorderLayout + * (Center) (East) + * |----------scrollTable----------|-scrollEast-| + * | | | + * | | | + * | | | + * | | | + * | table | | + * | | | + * | | | + * | |------------| + * | | panButtons | + * | | | + * |----------------panParam12Events------------| + * |-------scrollParam12---------|-scrollEvents-| + * |-----------|-----------|--------------------| + * | panParam1 | panParam2 | taEvents | + * |-----------|-----------|--------------------| + * (South) + *+ * + * @author darius.matulis@ktu.lt + */ +public class MainWindow extends JFrame implements ActionListener { + + private static final ResourceBundle MESSAGES = ResourceBundle.getBundle("edu.ktu.ds.lab3.gui.messages"); + + private static final int TF_WIDTH = 6; + private static final int NUMBER_OF_BUTTONS = 3; + + private final JComboBox
+ * |-------------------------------| + * | |------------| | + * | lblTexts[0] | tfTexts[0] | | + * | |------------| | + * | | + * | |------------| | + * | lblTexts[1] | tfTexts[1] | | + * | |------------| | + * | ... ... | + * |-------------------------------| + *+ * + * @param lblTexts + * @param tfTexts + * @param columnWidth + */ + public Panels(String[] lblTexts, String[] tfTexts, int columnWidth) { + super(); + if (lblTexts == null || tfTexts == null) { + throw new IllegalArgumentException("Arguments for table of parameters are incorrect"); + } + this.tfTexts = Arrays.stream(tfTexts).collect(Collectors.toList()); + List
+ * |-------------------------------------| + * | |-------------| |-------------| | + * | | btnNames[0] | | btnNames[1] | ... | + * | |-------------| |-------------| | + * | | + * | |-------------| |-------------| | + * | | btnNames[2] | | btnNames[3] | ... | + * | |-------------| |-------------| | + * | ... ... | + * |-------------------------------------| + *+ * + * @param btnNames + * @param gridX + * @param gridY + */ + public Panels(String[] btnNames, int gridX, int gridY) { + super(); + if (btnNames == null || gridX < 1 || gridY < 1) { + throw new IllegalArgumentException("Arguments for buttons grid are incorrect"); + } + initGridOfButtons(gridX, gridY, Arrays.stream(btnNames).collect(Collectors.toList())); + } + + private void initTableOfParameters(int columnWidth, List
+ * Tai yra interfeisas, kurį turi tenkinti KTU studentų kuriamos duomenų klasės
+ * Metodai užtikrina patogų duomenų suformavimą iš String eilučių
+ ******************************************************************************/
+public interface Parsable