2024-10-09 22:21:57 +03:00
|
|
|
package _VisualDVM.GlobalData.CompilerOption;
|
2024-10-07 00:58:29 +03:00
|
|
|
import Common.Database.Tables.DataSet;
|
2024-10-08 00:39:13 +03:00
|
|
|
import Common.Visual.DataSetControlForm;
|
2024-10-15 15:13:57 +03:00
|
|
|
import Common.Visual.Tables.RendererMultiline;
|
|
|
|
|
import _VisualDVM.GlobalData.CompilerOption.UI.CompilerOptionParameterNameRenderer;
|
|
|
|
|
import _VisualDVM.GlobalData.CompilerOption.UI.CompilerOptionParameterValueRenderer;
|
2023-09-17 22:13:42 +03:00
|
|
|
public class CompilerOptionsSet extends DataSet<String, CompilerOption> {
|
|
|
|
|
public CompilerOptionsSet() {
|
|
|
|
|
super(String.class, CompilerOption.class);
|
|
|
|
|
}
|
|
|
|
|
@Override
|
|
|
|
|
public String[] getUIColumnNames() {
|
|
|
|
|
return new String[]{
|
|
|
|
|
"Параметр", "Значение", "Описание"
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
|
@Override
|
|
|
|
|
public Object getFieldAt(CompilerOption object, int columnIndex) {
|
|
|
|
|
switch (columnIndex) {
|
|
|
|
|
case 2:
|
|
|
|
|
return object.parameterName + object.parameterSeparator;
|
|
|
|
|
case 3:
|
|
|
|
|
return object.parameterValue;
|
|
|
|
|
case 4:
|
|
|
|
|
return object.description;
|
|
|
|
|
default:
|
|
|
|
|
return null;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
@Override
|
|
|
|
|
protected DataSetControlForm createUI() {
|
|
|
|
|
return new DataSetControlForm(this) {
|
|
|
|
|
@Override
|
|
|
|
|
public boolean hasCheckBox() {
|
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
@Override
|
|
|
|
|
protected void AdditionalInitColumns() {
|
2024-10-15 15:13:57 +03:00
|
|
|
columns.get(2).setRendererClass( CompilerOptionParameterNameRenderer.class);
|
|
|
|
|
columns.get(3).setRendererClass(CompilerOptionParameterValueRenderer.class);
|
|
|
|
|
columns.get(3).setEditorClass(CompilerOptionParameterValueRenderer.class);
|
|
|
|
|
columns.get(4).setRendererClass(RendererMultiline.class);
|
2023-09-17 22:13:42 +03:00
|
|
|
}
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
|
}
|