regenerated by the Form Editor.
*/
@SuppressWarnings(“unchecked”)
//
private void initComponents() {
jScrollPane3 = new javax.swing.JScrollPane();
jTree1 = new javax.swing.JTree();
jTabbedPane1 = new javax.swing.JTabbedPane();
jPanel3 = new javax.swing.JPanel();
LblNomeFuncionario = new javax.swing.JLabel();
TxtNomeFuncionario = new javax.swing.JTextField();
LblCpfFuncionario = new javax.swing.JLabel();
LblEmailFuncionario = new javax.swing.JLabel();
TxtEmailFuncionario = new javax.swing.JTextField();
LblSalarioFuncionario = new javax.swing.JLabel();
LblDescricaoFuncionario = new javax.swing.JLabel();
jScrollPane2 = new javax.swing.JScrollPane();
TxtDescricaoFuncionario = new javax.swing.JTextArea();
LblFuncaoFuncionario = new javax.swing.JLabel();
DdlFuncaoFuncionario = new javax.swing.JComboBox();
BtnSalvarFuncionario = new javax.swing.JButton();
TxtCpfFuncionario = new javax.swing.JFormattedTextField();
TxtSalarioFuncionario = new javax.swing.JTextField();
LblIdFuncionario = new javax.swing.JLabel();
jScrollPane1 = new javax.swing.JScrollPane();
jTable1 = new javax.swing.JTable();
jPanel1 = new javax.swing.JPanel();
LblCadastroFuncionario = new javax.swing.JLabel();
jPanel2 = new javax.swing.JPanel();
LblFiltroFuncionario = new javax.swing.JLabel();
TxtFiltroFuncionario = new javax.swing.JTextField();
BtnFiltrarFuncionario = new javax.swing.JButton();
BtnListarFuncionario = new javax.swing.JButton();
BtnIncluirFuncionario = new javax.swing.JButton();
BtnExcluirFuncionario = new javax.swing.JButton();
jScrollPane3.setViewportView(jTree1);
setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
setTitle(“Cadastro de Funcionário”);
jTabbedPane1.setPreferredSize(new java.awt.Dimension(440, 390));
jPanel3.setPreferredSize(new java.awt.Dimension(413, 210));
LblNomeFuncionario.setText(“Nome”);
TxtNomeFuncionario.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
TxtNomeFuncionarioActionPerformed(evt);
}
});
LblCpfFuncionario.setText(“CPF”);
LblEmailFuncionario.setText(“E-mail”);
LblSalarioFuncionario.setText(“Salário”);
LblDescricaoFuncionario.setText(“Descrição”);
TxtDescricaoFuncionario.setColumns(20);
TxtDescricaoFuncionario.setRows(5);
jScrollPane2.setViewportView(TxtDescricaoFuncionario);
LblFuncaoFuncionario.setText(“Função”);
DdlFuncaoFuncionario.setModel(new javax.swing.DefaultComboBoxModel(new String[] { “Caixa”, “Garçon”, “Cozinheiro” }));
BtnSalvarFuncionario.setText(“Salvar”);
BtnSalvarFuncionario.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
BtnSalvarFuncionarioActionPerformed(evt);
}
});
try {
TxtCpfFuncionario.setFormatterFactory(new javax.swing.text.DefaultFormatterFactory(new javax.swing.text.MaskFormatter("###.###.###-##")));
} catch (java.text.ParseException ex) {
ex.printStackTrace();
}
javax.swing.GroupLayout jPanel3Layout = new javax.swing.GroupLayout(jPanel3);
jPanel3.setLayout(jPanel3Layout);
jPanel3Layout.setHorizontalGroup(
jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel3Layout.createSequentialGroup()
.addContainerGap()
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
.addComponent(BtnSalvarFuncionario)
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
.addGroup(jPanel3Layout.createSequentialGroup()
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel3Layout.createSequentialGroup()
.addComponent(LblNomeFuncionario)
.addGap(18, 18, 18)
.addComponent(TxtNomeFuncionario, javax.swing.GroupLayout.PREFERRED_SIZE, 193, javax.swing.GroupLayout.PREFERRED_SIZE)
.addGap(18, 18, 18)
.addComponent(LblCpfFuncionario))
.addGroup(jPanel3Layout.createSequentialGroup()
.addComponent(LblEmailFuncionario)
.addGap(18, 18, 18)
.addComponent(TxtEmailFuncionario, javax.swing.GroupLayout.PREFERRED_SIZE, 142, javax.swing.GroupLayout.PREFERRED_SIZE)
.addGap(63, 63, 63)
.addComponent(LblSalarioFuncionario)))
.addGap(18, 18, 18)
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addComponent(TxtCpfFuncionario, javax.swing.GroupLayout.PREFERRED_SIZE, 84, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(TxtSalarioFuncionario, javax.swing.GroupLayout.DEFAULT_SIZE, 85, Short.MAX_VALUE)))
.addGroup(jPanel3Layout.createSequentialGroup()
.addComponent(LblDescricaoFuncionario)
.addGap(27, 27, 27)
.addComponent(LblIdFuncionario)
.addGap(144, 144, 144)
.addComponent(LblFuncaoFuncionario)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
.addComponent(DdlFuncaoFuncionario, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
.addComponent(jScrollPane2)))
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
);
jPanel3Layout.setVerticalGroup(
jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel3Layout.createSequentialGroup()
.addContainerGap()
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(LblNomeFuncionario)
.addComponent(TxtNomeFuncionario, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(LblCpfFuncionario)
.addComponent(TxtCpfFuncionario, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(LblEmailFuncionario)
.addComponent(TxtEmailFuncionario, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(LblSalarioFuncionario)
.addComponent(TxtSalarioFuncionario, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(LblFuncaoFuncionario)
.addComponent(DdlFuncaoFuncionario, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(LblDescricaoFuncionario)
.addComponent(LblIdFuncionario))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 63, javax.swing.GroupLayout.PREFERRED_SIZE)
.addGap(18, 18, 18)
.addComponent(BtnSalvarFuncionario)
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
);
jTabbedPane1.addTab(“Cadastro”, jPanel3);
jTable1.setModel(new javax.swing.table.DefaultTableModel(
new Object [][] {
{null, null, null, null, null, “”, null},
{null, null, null, null, null, null, null},
{null, null, null, null, null, null, null},
{null, null, null, null, null, null, null}
},
new String [] {
“Nome”, “CPF”, “Função”, “Título 4”, “Título 5”, “Título 6”, “Título 7”
}
) {
Class[] types = new Class [] {
java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.Object.class, java.lang.Object.class, java.lang.Object.class, java.lang.Object.class
};
public Class getColumnClass(int columnIndex) {
return types [columnIndex];
}
});
jTable1.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
jTable1MouseClicked(evt);
}
});
jScrollPane1.setViewportView(jTable1);
jTable1.getColumnModel().getColumn(3).setMinWidth(0);
jTable1.getColumnModel().getColumn(3).setPreferredWidth(0);
jTable1.getColumnModel().getColumn(3).setMaxWidth(0);
jTable1.getColumnModel().getColumn(4).setMinWidth(0);
jTable1.getColumnModel().getColumn(4).setPreferredWidth(0);
jTable1.getColumnModel().getColumn(4).setMaxWidth(0);
jTable1.getColumnModel().getColumn(5).setMinWidth(0);
jTable1.getColumnModel().getColumn(5).setPreferredWidth(0);
jTable1.getColumnModel().getColumn(5).setMaxWidth(0);
jTable1.getColumnModel().getColumn(6).setMinWidth(0);
jTable1.getColumnModel().getColumn(6).setPreferredWidth(0);
jTable1.getColumnModel().getColumn(6).setMaxWidth(0);
jTabbedPane1.addTab(“Lista Funcionários”, jScrollPane1);
getContentPane().add(jTabbedPane1, java.awt.BorderLayout.CENTER);
LblCadastroFuncionario.setFont(new java.awt.Font(“Arial”, 1, 18));
LblCadastroFuncionario.setText(“Cadastro de Funcionário”);
javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
jPanel1.setLayout(jPanel1Layout);
jPanel1Layout.setHorizontalGroup(
jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()
.addContainerGap(101, Short.MAX_VALUE)
.addComponent(LblCadastroFuncionario)
.addGap(97, 97, 97))
);
jPanel1Layout.setVerticalGroup(
jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addContainerGap()
.addComponent(LblCadastroFuncionario)
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
);
getContentPane().add(jPanel1, java.awt.BorderLayout.PAGE_START);
LblFiltroFuncionario.setText(“Filtrar por”);
BtnFiltrarFuncionario.setText(“Filtrar”);
BtnListarFuncionario.setText(“Listar”);
BtnIncluirFuncionario.setText(“Incluir”);
BtnExcluirFuncionario.setText(“Excluir”);
BtnExcluirFuncionario.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
BtnExcluirFuncionarioActionPerformed(evt);
}
});
javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);
jPanel2.setLayout(jPanel2Layout);
jPanel2Layout.setHorizontalGroup(
jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel2Layout.createSequentialGroup()
.addContainerGap()
.addComponent(LblFiltroFuncionario)
.addGap(18, 18, 18)
.addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addComponent(TxtFiltroFuncionario, javax.swing.GroupLayout.DEFAULT_SIZE, 326, Short.MAX_VALUE)
.addGroup(jPanel2Layout.createSequentialGroup()
.addComponent(BtnFiltrarFuncionario)
.addGap(18, 18, 18)
.addComponent(BtnListarFuncionario)
.addGap(18, 18, 18)
.addComponent(BtnIncluirFuncionario)
.addGap(18, 18, 18)
.addComponent(BtnExcluirFuncionario)
.addGap(0, 28, Short.MAX_VALUE)))
.addContainerGap())
);
jPanel2Layout.setVerticalGroup(
jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel2Layout.createSequentialGroup()
.addContainerGap()
.addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(LblFiltroFuncionario)
.addComponent(TxtFiltroFuncionario, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
.addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(BtnFiltrarFuncionario)
.addComponent(BtnListarFuncionario)
.addComponent(BtnIncluirFuncionario)
.addComponent(BtnExcluirFuncionario))
.addContainerGap(15, Short.MAX_VALUE))
);
getContentPane().add(jPanel2, java.awt.BorderLayout.PAGE_END);
pack();
}//