The "mainPanel" is just a container in which I drop one of the pre-made JPanels that are constructed separately. I though it will be easier to just drop pre-made component in JPanel and then do the cleaning with removeAll when different option selected. Right now I have only 3 panels
private AddEmployeePanel addEP = new AddEmployeePanel();
private EditEmployeePanel editEP = new EditEmployeePanel();
private AllClientsPanel allCP = new AllClientsPanel();
which are placed in "mainPanel" depending on pressed option