Warning: Trying to access array offset on value of type bool in /home/feltexco/public_html/felix/wp-content/plugins/google-maps-ready/modules/options/models/options.php on line 16

Warning: Trying to access array offset on value of type bool in /home/feltexco/public_html/felix/wp-content/plugins/google-maps-ready/modules/options/models/options.php on line 16

Warning: Trying to access array offset on value of type bool in /home/feltexco/public_html/felix/wp-content/plugins/google-maps-ready/modules/options/models/options.php on line 16

Warning: Cannot modify header information - headers already sent by (output started at /home/feltexco/public_html/felix/wp-content/plugins/google-maps-ready/modules/options/models/options.php:16) in /home/feltexco/public_html/felix/wp-includes/rest-api/class-wp-rest-server.php on line 1758

Warning: Cannot modify header information - headers already sent by (output started at /home/feltexco/public_html/felix/wp-content/plugins/google-maps-ready/modules/options/models/options.php:16) in /home/feltexco/public_html/felix/wp-includes/rest-api/class-wp-rest-server.php on line 1758

Warning: Cannot modify header information - headers already sent by (output started at /home/feltexco/public_html/felix/wp-content/plugins/google-maps-ready/modules/options/models/options.php:16) in /home/feltexco/public_html/felix/wp-includes/rest-api/class-wp-rest-server.php on line 1758

Warning: Cannot modify header information - headers already sent by (output started at /home/feltexco/public_html/felix/wp-content/plugins/google-maps-ready/modules/options/models/options.php:16) in /home/feltexco/public_html/felix/wp-includes/rest-api/class-wp-rest-server.php on line 1758

Warning: Cannot modify header information - headers already sent by (output started at /home/feltexco/public_html/felix/wp-content/plugins/google-maps-ready/modules/options/models/options.php:16) in /home/feltexco/public_html/felix/wp-includes/rest-api/class-wp-rest-server.php on line 1758

Warning: Cannot modify header information - headers already sent by (output started at /home/feltexco/public_html/felix/wp-content/plugins/google-maps-ready/modules/options/models/options.php:16) in /home/feltexco/public_html/felix/wp-includes/rest-api/class-wp-rest-server.php on line 1758

Warning: Cannot modify header information - headers already sent by (output started at /home/feltexco/public_html/felix/wp-content/plugins/google-maps-ready/modules/options/models/options.php:16) in /home/feltexco/public_html/felix/wp-includes/rest-api/class-wp-rest-server.php on line 1758

Warning: Cannot modify header information - headers already sent by (output started at /home/feltexco/public_html/felix/wp-content/plugins/google-maps-ready/modules/options/models/options.php:16) in /home/feltexco/public_html/felix/wp-includes/rest-api/class-wp-rest-server.php on line 1758
{"id":594,"date":"2014-05-02T12:09:41","date_gmt":"2014-05-02T15:09:41","guid":{"rendered":"http:\/\/www.feltex.com.br\/felix\/?p=594"},"modified":"2014-11-17T11:39:45","modified_gmt":"2014-11-17T13:39:45","slug":"criando-projeto-enterprise-netbeans","status":"publish","type":"post","link":"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/","title":{"rendered":"Criando um Projeto Enterprise no Netbeans"},"content":{"rendered":"

Criando um Projeto Enterprise no Netbeans<\/H1>
\nOl\u00e1 Amigos<\/p>\n

O NetBeans \u00e9 a IDE oficial da Oracle. Ele tem como vantagem a utiliza\u00e7\u00e3o de Wizards<\/i> bem mais robustos e completos que outras IDEs. Isto diminui a curva de aprendizado e nos auxiliam no aprendizado de novas tecnologias.
\n Iremos criar um projeto Enterprise (EAR) completo com m\u00f3dulos EJB e WEB (JSP + Servlet + EJB + JPA + MySQL).<\/p>\n

<\/p>\n

Criando o primeiro Projeto Enterprise<\/H2><\/p>\n

O roteiro:
\n Faremos um projeto com as seguintes caracter\u00edsticas:
\n \u2022\tWeb (JSP + Servlet) Padr\u00e3o de projeto MVC
\n \u2022\tComponentes Corporativos (EJB + JPA) Padr\u00e3o de projeto DAO
\n \u2022\tUso de Inje\u00e7\u00e3o de depend\u00eancia, invers\u00e3o de controle, Anota\u00e7\u00f5es
\n Seguiremos os seguintes passos
\n 1. Criar Data Souce ABA (Clique aqui<\/a>)
\n 2. Criar projeto EAR (JEE aplicativo Corporativo)
\n 3. Modulos EJB e WEB
\n 4. Criar entidades UP
\n 5. Criar EJB
\n 6. Entity Manage
\n 7. Servlet (@EJB)
\n 8. JSP<\/p>\n


\n M\u00e3os \u00e0 obra
\n

1. Cria\u00e7\u00e3o do Data Source<\/H2>
\n Siga os passos deste post
Clique aqui<\/a>.<\/p>\n

2. Criar projeto EAR (JEE aplicativo Corporativo)<\/H2>
\n Criando o primeiro Projeto Enterprise.<\/p>\n

1. Vamos criar o projeto agora.
\n2. Acesse o menu Arquivo >> Novo projeto ou Ctrl + Shift + N<\/p>\n

\"Criando<\/a><\/p>\n

3. Na janela seguinte selecione em Categoria \u201cJava EE\u201d e em projetos \u201cAplicativo Enterprise\u201d em seguida selecione o bot\u00e3o \u201cPr\u00f3ximo\u201d.<\/p>\n

\"Criando<\/a><\/p>\n

4. Escreva o nome do projeto \u201cAcademicNet\u201d.
\n Aten\u00e7\u00e3o: N\u00e3o deixe espa\u00e7o no path do projeto. Caso contr\u00e1rio podem ocorrer erros na compila\u00e7\u00e3o.<\/b><\/p>\n

\"Criando<\/a><\/p>\n

5. Selecione pr\u00f3ximo.<\/p>\n

\"Criando<\/a><\/p>\n

6. Marque as op\u00e7\u00f5es de \u201cCriar m\u00f3dulo EJB\u201d e \u201cCriar m\u00f3dulo de aplicativo Web\u201d
\n7. Selecione Finalizar
\n8. O seu projeto deve ficar desta forma:<\/p>\n

\"Criando<\/a><\/p>\n

Criando a tela para preenchimento dos dados<\/h2>\n

1. Selecione o projeto web
\n 2. Clique com o bot\u00e3o direito, selecione novo e escolha \u201cJSP…\u201d<\/p>\n

\"Criando<\/a><\/p>\n

3. Nomeie o arquivo como “aluno”<\/p>\n

\"Criando<\/a><\/p>\n

4. Selecione finalizar
\n5. Escreva na p\u00e1gina o c\u00f3digo a seguir:<\/p>\n

\r\n\r\n\r\n\r\nCadastro de Aluno<\/title>\r\n<\/head>\r\n<body>\r\n\t<div align=\"center\">\r\n\t\t<form method=\"post\" action=\"AlunoServlet\">\r\n\t\t\t<fieldset>\r\n\t\t\t\t<legend>Cadastro de Alunos<\/legend>\r\n\t\t\t\t<label>Matr\u00edcula: <\/label><input name=\"matricula\" required\r\n\t\t\t\t    value=\"${aluno.matricula}\"\r\n\t\t\t\t\tplaceholder=\"2236541\" \/><br \/> \r\n\t\t\t\t<label>Name:<\/label><input\r\n\t\t\t\t\tname=\"nome\" autofocus=\"autofocus\" placeholder=\"Nome\"  value=\"${aluno.nome}\"\/><br \/>\r\n\t\t\t\t\t\r\n\t\t\t\t <label>Telefone:<\/label><input\r\n\t\t\t\t\ttype=\"tel\" name=\"telefone\" placeholder=\"9999-9999\" value=\"${aluno.telefone}\" \/><br \/>\r\n\t\t\t\t <label>Email:<\/label><input\r\n\t\t\t\t\ttype=\"email\" name=\"email\" placeholder=\"andre@feltex.com.br\"  value=\"${aluno.email}\"\/><br \/>\t\r\n\t\t\t\t<label>Data Cadastro:<\/label><input type=\"date\" name=\"dataCadastro\" value=\"${aluno.dataCadastro}\"\r\n\t\t\t\t\tplaceholder=\"10\/10\/2014\" \/><br \/> <label>A\u00e7\u00e3o<\/label> <select\r\n\t\t\t\t\tname=\"acao\" required>\r\n\t\t\t\t\t<option selected value=\"Incluir\">Incluir<\/option>\r\n\t\t\t\t\t<option value=\"Alterar\">Alterar<\/option>\r\n\t\t\t\t\t<option value=\"Excluir\">Excluir<\/option>\r\n\t\t\t\t\t<option value=\"Consultar\">Consultar<\/option>\r\n\t\t\t\t<\/select><br \/> <input type=\"submit\" value=\"Enviar\"> <input\r\n\t\t\t\t\ttype=\"reset\" value=\"Limpar\"> <br \/>\r\n\t\t\t<\/fieldset>\r\n\t\t<\/form>\r\n\t<\/div>\r\n<\/body>\r\n<\/html>\r\n<\/pre>\n<p>6. Crie um link para esta p\u00e1gina dentro o arquivo index.html<\/p>\n<pre lang=\"java\" line=\"1\">\r\n<!DOCTYPE html>\r\n<html>\r\n    <head>\r\n        <meta http-equiv=\"Content-Type\" content=\"text\/html; charset=UTF-8\">\r\n        <title>JSP Page<\/title>\r\n    <\/head>\r\n    <body>\r\n        <a href=\"aluno.jsp\">Cadastro de Aluno!<\/h1><\/a>\r\n <\/body>\r\n<\/html>\r\n<\/pre>\n<h2>Criando o Servlet<\/H2><\/p>\n<p>1. Selecione novamente o projeto web. Clique com o bot\u00e3o direito, escolha a op\u00e7\u00e3o \u201cServlet…\u201d<\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-8\/\" rel=\"attachment wp-att-620\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-8.png\" alt=\"Criando um Projeto Enterprise no Netbeans (8)\" width=\"519\" height=\"374\" class=\"aligncenter size-full wp-image-620\" srcset=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-8.png 519w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-8-300x216.png 300w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-8-416x300.png 416w\" sizes=\"(max-width: 519px) 100vw, 519px\" \/><\/a><\/p>\n<p>2. Preencha os dados conforme a seguinte tela e selecione pr\u00f3ximo<\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-9\/\" rel=\"attachment wp-att-621\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-9.png\" alt=\"Criando um Projeto Enterprise no Netbeans (9)\" width=\"713\" height=\"495\" class=\"aligncenter size-full wp-image-621\" srcset=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-9.png 713w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-9-300x208.png 300w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-9-432x300.png 432w\" sizes=\"(max-width: 713px) 100vw, 713px\" \/><\/a><\/p>\n<p>3. Observe que o nome do pacote n\u00e3o deve ser deixado em branco.<br \/>\n4.<b><u>No passo seguinte do wizard n\u00e3o marque a op\u00e7\u00e3o \u201cadicionar informa\u00e7\u00e3o ao descritor de implementa\u00e7\u00e3o (web.xml)\u201d, pois utilizaremos anota\u00e7\u00f5es.<\/u><b><\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-10\/\" rel=\"attachment wp-att-622\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-10.png\" alt=\"Criando um Projeto Enterprise no Netbeans (10)\" width=\"713\" height=\"495\" class=\"aligncenter size-full wp-image-622\" srcset=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-10.png 713w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-10-300x208.png 300w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-10-432x300.png 432w\" sizes=\"(max-width: 713px) 100vw, 713px\" \/><\/a><\/p>\n<p>5. Selecione finalizar. Agora o nosso servlet foi criado.<\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-11\/\" rel=\"attachment wp-att-623\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-11.png\" alt=\"Criando um Projeto Enterprise no Netbeans (11)\" width=\"839\" height=\"378\" class=\"aligncenter size-full wp-image-623\" srcset=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-11.png 839w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-11-300x135.png 300w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-11-500x225.png 500w\" sizes=\"(max-width: 839px) 100vw, 839px\" \/><\/a><\/p>\n<p>6. Agora devemos realizar a leitura dos dados da tela.<br \/>\n7. Mas antes devemos criar a classe de entidade que receber\u00e1 os dados da tela.<\/p>\n<p><H2> Criando Classe de entidade<\/H2><br \/>\n 1. As classes de entidade s\u00e3o criadas no projeto EJB. A raz\u00e3o \u00e9 bem clara, uma vez que os EJBs ser\u00e3o respons\u00e1veis por usar essas classes para persist\u00eancia atrav\u00e9s de JPA.<br \/>\n 2. Selecione o projeto EJB >> Novo >> \u201cClasse da entidade…\u201d.<\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-12\/\" rel=\"attachment wp-att-624\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-12.png\" alt=\"Criando um Projeto Enterprise no Netbeans (12)\" width=\"504\" height=\"263\" class=\"aligncenter size-full wp-image-624\" srcset=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-12.png 504w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-12-300x156.png 300w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-12-500x260.png 500w\" sizes=\"(max-width: 504px) 100vw, 504px\" \/><\/a><\/p>\n<p>3. Ser\u00e1 apresentada a seguinte tela:<\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-13\/\" rel=\"attachment wp-att-625\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-13.png\" alt=\"Criando um Projeto Enterprise no Netbeans (13)\" width=\"741\" height=\"515\" class=\"aligncenter size-full wp-image-625\" srcset=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-13.png 741w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-13-300x208.png 300w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-13-431x300.png 431w\" sizes=\"(max-width: 741px) 100vw, 741px\" \/><\/a><\/p>\n<p>4. Preencha os dados conforme a imagem. <b><u>N\u00e3o se esque\u00e7a de marcar a op\u00e7\u00e3o \u201cCriar unidade de persist\u00eancia\u201d. Selecione pr\u00f3ximo.<\/u><\/b><br \/>\n5. Ser\u00e1 exibida a tela com informa\u00e7\u00f5es da unidade de persist\u00eancia.<br \/>\n6. Na op\u00e7\u00e3o \u201cFonte de dados\u201d selecione \u201cNova fonte de dados…\u201d<\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-14\/\" rel=\"attachment wp-att-626\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-14.png\" alt=\"Criando um Projeto Enterprise no Netbeans (14)\" width=\"741\" height=\"471\" class=\"aligncenter size-full wp-image-626\" srcset=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-14.png 741w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-14-300x190.png 300w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-14-471x300.png 471w\" sizes=\"(max-width: 741px) 100vw, 741px\" \/><\/a><\/p>\n<p>7. Preencha a tela a seguir com os seguintes dados<\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-15\/\" rel=\"attachment wp-att-627\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-15.png\" alt=\"Criando um Projeto Enterprise no Netbeans (15)\" width=\"513\" height=\"197\" class=\"aligncenter size-full wp-image-627\" srcset=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-15.png 513w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-15-300x115.png 300w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-15-500x192.png 500w\" sizes=\"(max-width: 513px) 100vw, 513px\" \/><\/a><\/p>\n<p>8. jdbc >> \u00e9 um padr\u00e3o de nomenclatura para recursos de acesso a banco de dados<br \/>\n9. E a conex\u00e3o de banco de dados que escolhemos \u00e9 o data source que criamos no in\u00edcio deste manual.<br \/>\n10. Confirme (OK)<br \/>\n11. Deixe a \u201cEstrat\u00e9gia de gera\u00e7\u00e3o de tabela como \u2018Criar\u2019\u201d. Selecione finalizar.<br \/>\n12. Agora na entidade que acabamos de criar, vamos adicionar os atributos.<br \/>\n13. matricula, nome, telefone, email e dataCadastro.<\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-16\/\" rel=\"attachment wp-att-628\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-16.png\" alt=\"Criando um Projeto Enterprise no Netbeans (16)\" width=\"699\" height=\"284\" class=\"aligncenter size-full wp-image-628\" srcset=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-16.png 699w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-16-300x121.png 300w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-16-500x203.png 500w\" sizes=\"(max-width: 699px) 100vw, 699px\" \/><\/a><\/p>\n<p>14. Para gerar os m\u00e9todos Gets e Sets podemos clicar com o bot\u00e3o direito no c\u00f3digo e escolher \u201cinserir c\u00f3digo…\u201d ( Alt + insert) e selecionar \u201cGetter e Setter…\u201d<\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-17\/\" rel=\"attachment wp-att-629\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-17.png\" alt=\"Criando um Projeto Enterprise no Netbeans (17)\" width=\"229\" height=\"166\" class=\"aligncenter size-full wp-image-629\" \/><\/a><\/p>\n<p>16.\tAo selecionar os atributos os gets e sets ser\u00e3o criados automaticamente.<br \/>\n17.\tPara gerar o m\u00e9todo toString() podemos clicar com o bot\u00e3o direito no c\u00f3digo e escolher \u201cinserir toString…\u201d ( Alt + insert)  selecionar \u201ctoString()…\u201d<\/p>\n<p><H2> Cria\u00e7\u00e3o do EJB<\/H2><br \/>\nAgora vamos criar o EJB que far\u00e1 a persist\u00eancia dos dados no banco bdacademicnet.<br \/>\n1. Selecione o projeto EJB. Bot\u00e3o direito >> Novo >> Bean de Sess\u00e3o<\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-18\/\" rel=\"attachment wp-att-630\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-18.png\" alt=\"Criando um Projeto Enterprise no Netbeans (18)\" width=\"506\" height=\"263\" class=\"aligncenter size-full wp-image-630\" srcset=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-18.png 506w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-18-300x155.png 300w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-18-500x259.png 500w\" sizes=\"(max-width: 506px) 100vw, 506px\" \/><\/a><\/p>\n<p>2. Preencha os dados conforme a tela abaixo:<\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-19\/\" rel=\"attachment wp-att-631\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-19.png\" alt=\"Criando um Projeto Enterprise no Netbeans (19)\" width=\"741\" height=\"515\" class=\"aligncenter size-full wp-image-631\" srcset=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-19.png 741w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-19-300x208.png 300w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-19-431x300.png 431w\" sizes=\"(max-width: 741px) 100vw, 741px\" \/><\/a><\/p>\n<p>3. Selecione finalizar.<br \/>\n4. Assim temos um Bean Local e sem estado (Stateless)<\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-20\/\" rel=\"attachment wp-att-632\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-20.png\" alt=\"Criando um Projeto Enterprise no Netbeans (20)\" width=\"698\" height=\"313\" class=\"aligncenter size-full wp-image-632\" srcset=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-20.png 698w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-20-300x134.png 300w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-20-500x224.png 500w\" sizes=\"(max-width: 698px) 100vw, 698px\" \/><\/a><\/p>\n<p>5. Clique na classe e use a op\u00e7\u00e3o de inserir c\u00f3digo novamente (Alt + insert).<br \/>\n6. Escolha a op\u00e7\u00e3o \u201cUtilizar gerenciador de Entidade\u201d<\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-21\/\" rel=\"attachment wp-att-633\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-21.png\" alt=\"Criando um Projeto Enterprise no Netbeans (21)\" width=\"229\" height=\"166\" class=\"aligncenter size-full wp-image-633\" \/><\/a><\/p>\n<p>7. Este gerenciador de entidade \u00e9 a unidade de persist\u00eancia que criamos ao adicionar uma entidade ao projeto. Caso n\u00e3o se lembre disso volte ao passo de cria\u00e7\u00e3o da classe de entidade.<\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-22\/\" rel=\"attachment wp-att-634\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-22.png\" alt=\"Criando um Projeto Enterprise no Netbeans (22)\" width=\"702\" height=\"327\" class=\"aligncenter size-full wp-image-634\" srcset=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-22.png 702w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-22-300x139.png 300w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-22-500x232.png 500w\" sizes=\"(max-width: 702px) 100vw, 702px\" \/><\/a><\/p>\n<p>8. Observe que o m\u00e9todo de persist recebe um object, que \u00e9 PAI de todas as classes Java. Vamos especializar para a nossa classe Aluno.<br \/>\n9. Em seguida vamos criar os outros m\u00e9todos do CRUD.<\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-23\/\" rel=\"attachment wp-att-635\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-23.png\" alt=\"Criando um Projeto Enterprise no Netbeans (23)\" width=\"553\" height=\"496\" class=\"aligncenter size-full wp-image-635\" srcset=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-23.png 553w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-23-300x269.png 300w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-23-334x300.png 334w\" sizes=\"(max-width: 553px) 100vw, 553px\" \/><\/a><\/p>\n<pre lang=\"java\" line=\"1\">\r\npackage br.com.feltex.academicnet.ejb;\r\nimport java.util.List;\r\n\r\nimport javax.ejb.Stateless;\r\nimport javax.persistence.EntityManager;\r\nimport javax.persistence.PersistenceContext;\r\nimport javax.persistence.criteria.CriteriaQuery;\r\n\r\nimport br.com.feltex.academicnet.entidade.Aluno;\r\nimport br.com.feltex.academicnet.facade.AlunoFacade;\r\n\r\n@Stateless\r\n@LocalBean\r\npublic class AlunoEJB {\r\n\r\n\t@PersistenceContext\r\n\tEntityManager em;\r\n\r\n\tpublic AlunoFacadeImp() {\r\n\t}\r\n\r\n\tpublic void alterar(Aluno aluno) {\r\n\t\tem.merge(aluno);\r\n\t}\r\n\r\n\tpublic Aluno consultar(Aluno aluno) {\r\n\t\treturn em.find(Aluno.class, aluno.getMatricula());\r\n\t}\r\n\r\n\tpublic void excluir(Aluno aluno) {\r\n\t\taluno = consultar(aluno);\r\n\t\tif (aluno != null) {\r\n\t\t\tem.remove(aluno);\r\n\t\t}\r\n\t}\r\n\t\r\n\tpublic boolean existe(Aluno aluno) {\r\n\t\treturn (consultar(aluno) != null);\r\n\t}\r\n\r\n\tpublic void inserir(Aluno aluno) {\r\n\t\tem.persist(aluno);\r\n\t}\r\n\r\n\t@SuppressWarnings({ \"rawtypes\", \"unchecked\" })\r\n\tpublic List<Aluno> listar() {\r\n\t\tCriteriaQuery cq = em.getCriteriaBuilder().createQuery();\r\n\t\tcq.select(cq.from(Aluno.class));\r\n\t\treturn (List<Aluno>) em.createQuery(cq).getResultList();\r\n\t}\r\n}\r\n<\/pre>\n<p>10. Pronto. O nosso EJB j\u00e1 \u00e9 capaz de fazer as 4 opera\u00e7\u00f5es b\u00e1sicas com o Banco de dados.<\/p>\n<p><H2>Chamar o EJB do Servlet<\/H2><\/p>\n<p>Neste passo vamos preencher adicionar os dados da tela na entidade. Em seguida chamaremos o EJB para fazer a persist\u00eancia em nosso banco de dados.<br \/>\n1. Abra o servlet AlunoServlet dentro do projeto Web.<br \/>\n2. Utilize Alt + insert. Selecione \u201cChamar Enterprise Bean\u2026\u201d<\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-24\/\" rel=\"attachment wp-att-636\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-24.png\" alt=\"Criando um Projeto Enterprise no Netbeans (24)\" width=\"229\" height=\"166\" class=\"aligncenter size-full wp-image-636\" \/><\/a><\/p>\n<p>3. Procure o nosso EJB no projeto AcademicNet-ejb. <\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-25\/\" rel=\"attachment wp-att-637\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-25.png\" alt=\"Criando um Projeto Enterprise no Netbeans (25)\" width=\"434\" height=\"615\" class=\"aligncenter size-full wp-image-637\" srcset=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-25.png 434w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-25-211x300.png 211w\" sizes=\"(max-width: 434px) 100vw, 434px\" \/><\/a><\/p>\n<p>4. Confirme a sele\u00e7\u00e3o.<br \/>\n5. Agora precisamos receber os dados da tela.<br \/>\n6. Adicione ao m\u00e9todo processRequest(….) a cria\u00e7\u00e3o de uma classe Aluno, realize os sets necess\u00e1rios e em seguida utilize o m\u00e9todo persist do EJB.<\/p>\n<p><a href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/criando-um-projeto-enterprise-no-netbeans-26\/\" rel=\"attachment wp-att-638\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-26.png\" alt=\"Criando um Projeto Enterprise no Netbeans (26)\" width=\"882\" height=\"433\" class=\"aligncenter size-full wp-image-638\" srcset=\"https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-26.png 882w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-26-300x147.png 300w, https:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-26-500x245.png 500w\" sizes=\"(max-width: 882px) 100vw, 882px\" \/><\/a><\/p>\n<pre lang=\"java\" line=\"1\">\r\npackage br.com.feltex.academicnet.servlet;\r\n\r\nimport br.com.feltex.academicnet.ejb.AlunoEJB;\r\nimport br.com.feltex.academicnet.entidade.Aluno;\r\nimport java.io.IOException;\r\nimport java.io.PrintWriter;\r\nimport java.text.DateFormat;\r\nimport java.text.SimpleDateFormat;\r\nimport java.util.ArrayList;\r\nimport java.util.List;\r\nimport javax.ejb.EJB;\r\nimport javax.servlet.RequestDispatcher;\r\nimport javax.servlet.ServletException;\r\nimport javax.servlet.annotation.WebServlet;\r\nimport javax.servlet.http.HttpServlet;\r\nimport javax.servlet.http.HttpServletRequest;\r\nimport javax.servlet.http.HttpServletResponse;\r\n\r\n\/**\r\n *\r\n * @author F\u00e9lix\r\n *\/\r\n@WebServlet(name = \"AlunoServlet\", urlPatterns = {\"\/AlunoServlet\"})\r\npublic class AlunoServlet extends HttpServlet {\r\n    @EJB\r\n    private AlunoEJB alunoEJB;  \r\n    protected void processRequest(HttpServletRequest request, HttpServletResponse response)\r\n            throws ServletException, IOException {\r\n        \r\n        String acao = request.getParameter(\"acao\");\r\n\t\tString destino = \"sucesso.jsp\";\r\n\t\tString mensagem = \"\";\r\n\t\tList<Aluno> lista = new ArrayList<>();\r\n\t\tAluno aluno = new Aluno();\r\n\t\t\r\n\t\ttry {\r\n\t\t\t\/\/Se a a\u00e7\u00e3o for DIFERENTE de Listar s\u00e3o lidos os dados da tela\r\n\t\t\tif (!acao.equalsIgnoreCase(\"Listar\")) {\r\n\t\t\t\taluno.setMatricula(Long.parseLong(request.getParameter(\"matricula\")));\r\n\t\t\t\taluno.setNome(request.getParameter(\"nome\"));\r\n\t\t\t\taluno.setTelefone(request.getParameter(\"telefone\"));\r\n\t\t\t\taluno.setEmail(request.getParameter(\"email\"));\r\n\t\t\t\t\r\n\t\t\t\t\/\/Faz a leitura da data de cadastro. Caso ocorra um erro de formata\u00e7\u00e3o\r\n\t\t\t\t\/\/ o sistema utilizar\u00e1 a data atual\r\n\t\t\t\ttry {\r\n\t\t\t\t\tDateFormat df = new SimpleDateFormat(\"dd\/MM\/yyyy\");\t\t\t\t\t\r\n\t\t\t\t\taluno.setDataCadastro(df.parse(request.getParameter(\"dataCadastro\")));\r\n\t\t\t\t} catch (Exception e) {\r\n\t\t\t\t\taluno.setDataCadastro(new Date());\t\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t}\r\n\r\n\t\t\tif (acao.equalsIgnoreCase(\"Incluir\")) {\r\n\t\t\t\t\/\/ Verifica se a matr\u00edcula informada j\u00e1 existe no Banco de Dados\r\n\t\t\t\t\/\/ Se existir enviar uma mensagem sen\u00e3o faz a inclus\u00e3o\r\n\t\t\t\tif (alunoEJB.existe(aluno)) {\r\n\t\t\t\t\tmensagem = \"Matr\u00edcula informada j\u00e1 existe!\";\r\n\t\t\t\t} else {\r\n\t\t\t\t\talunoEJB.inserir(aluno);\r\n\t\t\t\t}\r\n\t\t\t} else if (acao.equalsIgnoreCase(\"Alterar\")) {\r\n\t\t\t\talunoEJB.alterar(aluno);\r\n\t\t\t} else if (acao.equalsIgnoreCase(\"Excluir\")) {\r\n\t\t\t\talunoEJB.excluir(aluno);\r\n\t\t\t} else if (acao.equalsIgnoreCase(\"Consultar\")) {\r\n\t\t\t\trequest.setAttribute(\"aluno\", aluno);\r\n\t\t\t\taluno = alunoEJB.consultar(aluno);\r\n\t\t\t\tdestino = \"aluno.jsp\";\r\n\t\t\t}\r\n\t\t} catch (Exception e) {\r\n\t\t\tmensagem += e.getMessage();\r\n\t\t\tdestino = \"erro.jsp\";\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\t\r\n\t\t\/\/ Se a mensagem estiver vazia significa que houve sucesso!\r\n\t\t\/\/ Sen\u00e3o ser\u00e1 exibida a tela de erro do sistema.\r\n\t\tif (mensagem.length() == 0) {\r\n\t\t\tmensagem = \"Aluno Cadastrado com sucesso!\";\r\n\t\t} else {\r\n\t\t\tdestino = \"erro.jsp\";\r\n\t\t}\r\n\r\n\t\t\/\/ Lista todos os registros existente no Banco de Dados\r\n\t\tlista = alunoEJB.listar();\r\n\t\trequest.setAttribute(\"listaAluno\", lista);\r\n\t\trequest.setAttribute(\"mensagem\", mensagem);\r\n\t\t\r\n\r\n\t\t\/\/O sistema \u00e9 direcionado para a p\u00e1gina \r\n\t\t\/\/sucesso.jsp Se tudo ocorreu bem\r\n\t\t\/\/erro.jsp se houver algum problema.\r\n\t\tRequestDispatcher rd = request.getRequestDispatcher(destino);\r\n\t\trd.forward(request, response);\r\n        \r\n        \r\n        response.setContentType(\"text\/html;charset=UTF-8\");\r\n        try (PrintWriter out = response.getWriter()) {\r\n            \/* TODO output your page here. You may use following sample code. *\/\r\n            out.println(\"<!DOCTYPE html>\");\r\n            out.println(\"<html>\");\r\n            out.println(\"<head>\");\r\n            out.println(\"<\/head>\");\r\n            out.println(\"<body>\");\r\n            out.println(\"<h1>Servlet AlunoServlet at \" + request.getContextPath() + \"<\/h1>\");\r\n            out.println(\"<\/body>\");\r\n            out.println(\"<\/html>\");\r\n        }\r\n    }\r\n\r\n    \/\/ <editor-fold defaultstate=\"collapsed\" desc=\"HttpServlet methods. Click on the + sign on the left to edit the code.\">\r\n    \/**\r\n     * Handles the HTTP <code>GET<\/code> method.\r\n     *\r\n     * @param request servlet request\r\n     * @param response servlet response\r\n     * @throws ServletException if a servlet-specific error occurs\r\n     * @throws IOException if an I\/O error occurs\r\n     *\/\r\n    @Override\r\n    protected void doGet(HttpServletRequest request, HttpServletResponse response)\r\n            throws ServletException, IOException {\r\n        processRequest(request, response);\r\n    }\r\n\r\n    \/**\r\n     * Handles the HTTP <code>POST<\/code> method.\r\n     *\r\n     * @param request servlet request\r\n     * @param response servlet response\r\n     * @throws ServletException if a servlet-specific error occurs\r\n     * @throws IOException if an I\/O error occurs\r\n     *\/\r\n    @Override\r\n    protected void doPost(HttpServletRequest request, HttpServletResponse response)\r\n            throws ServletException, IOException {\r\n        processRequest(request, response);\r\n    }\r\n\r\n    \/**\r\n     * Returns a short description of the servlet.\r\n     *\r\n     * @return a String containing servlet description\r\n     *\/\r\n    @Override\r\n    public String getServletInfo() {\r\n        return \"Short description\";\r\n    }\/\/ <\/editor-fold>\r\n}\r\n<\/pre>\n<p>7. Pronto. Nosso sistema est\u00e1 completo. A Chamada \u00e9 feita com o seguinte fluxo (JSP >> Servlet >> EJB >> JPA >> Banco de Dados).<br \/>\nAbra\u00e7os e bons estudos.<\/p>\n<p><H2>Links relacionados<\/H2><\/p>\n<p>Leia tamb\u00e9m: <a href=\"https:\/\/www.feltex.com.br\/felix\/exemplo-completo-com-jsf-ejb-hibernate-mysql\/\" title=\"Exemplo completo com JSF Primefaces + EJB + Hibernate + MySQL\" target=\"_blank\">Exemplo completo com JSF Primefaces + EJB + Hibernate + MySQL<\/a><\/p>\n<p>Recomendo que leia:  <a href=\"https:\/\/www.feltex.com.br\/felix\/exemplo-completo-com-jsf-primefaces-ejb-hibernate-mysql-jms-topic\/\" title=\"Exemplo completo com JSF Primefaces + EJB + Hibernate + MySQL + JMS (Topic)\">Exemplo completo com JSF Primefaces + EJB + Hibernate + MySQL + JMS (Topic)<\/a><\/p>\n<p>Voc\u00ea ir\u00e1 gostar: <a href=\"https:\/\/www.feltex.com.br\/felix\/exemplo-completo-com-jsf-primefaces-hibernate-mysql\/\" title=\"Exemplo completo com JSF Primefaces + Hibernate + MySQL\" target=\"_blank\">Exemplo completo com JSF Primefaces + Hibernate + MySQL<\/a><\/p>\n<!-- AddThis Advanced Settings generic via filter on the_content --><!-- AddThis Share Buttons generic via filter on the_content -->","protected":false},"excerpt":{"rendered":"<p>Criando um Projeto Enterprise no Netbeans Ol\u00e1 Amigos O NetBeans \u00e9 a IDE oficial da Oracle. Ele tem como vantagem a utiliza\u00e7\u00e3o de Wizards bem mais robustos e completos que outras IDEs. Isto diminui a curva de aprendizado e nos …<\/p>\n<p class=\"read-more\"> <a class=\"more-link\" href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/\"> <span class=\"screen-reader-text\">Criando um Projeto Enterprise no Netbeans<\/span> Read More »<\/a><\/p>\n<p><!-- AddThis Advanced Settings generic via filter on get_the_excerpt --><!-- AddThis Share Buttons generic via filter on get_the_excerpt --><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"ngg_post_thumbnail":0},"categories":[1],"tags":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v17.9 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Criando um Projeto Enterprise no Netbeans<\/title>\n<meta name=\"description\" content=\"Criando um Projeto Enterprise no Netbeans\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/\" \/>\n<meta property=\"og:locale\" content=\"pt_BR\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Criando um Projeto Enterprise no Netbeans\" \/>\n<meta property=\"og:description\" content=\"Criando um Projeto Enterprise no Netbeans\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/\" \/>\n<meta property=\"og:site_name\" content=\"Aprenda Java\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/feltex.br\" \/>\n<meta property=\"article:published_time\" content=\"2014-05-02T15:09:41+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2014-11-17T13:39:45+00:00\" \/>\n<meta property=\"og:image\" content=\"http:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-1.png\" \/>\n<meta name=\"twitter:label1\" content=\"Escrito por\" \/>\n\t<meta name=\"twitter:data1\" content=\"Andr\u00e9 F\u00e9lix\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. tempo de leitura\" \/>\n\t<meta name=\"twitter:data2\" content=\"8 minutos\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.feltex.com.br\/felix\/#website\",\"url\":\"https:\/\/www.feltex.com.br\/felix\/\",\"name\":\"Aprenda Java\",\"description\":\"Cursos de java, SQL e Engenharia de Software\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.feltex.com.br\/felix\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"pt-BR\"},{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/#primaryimage\",\"inLanguage\":\"pt-BR\",\"url\":\"http:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-1.png\",\"contentUrl\":\"http:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-1.png\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/#webpage\",\"url\":\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/\",\"name\":\"Criando um Projeto Enterprise no Netbeans\",\"isPartOf\":{\"@id\":\"https:\/\/www.feltex.com.br\/felix\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/#primaryimage\"},\"datePublished\":\"2014-05-02T15:09:41+00:00\",\"dateModified\":\"2014-11-17T13:39:45+00:00\",\"author\":{\"@id\":\"https:\/\/www.feltex.com.br\/felix\/#\/schema\/person\/1e49f842c6254b4561b66ccf573c2069\"},\"description\":\"Criando um Projeto Enterprise no Netbeans\",\"breadcrumb\":{\"@id\":\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/#breadcrumb\"},\"inLanguage\":\"pt-BR\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Criando um Projeto Enterprise no Netbeans\"}]},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.feltex.com.br\/felix\/#\/schema\/person\/1e49f842c6254b4561b66ccf573c2069\",\"name\":\"Andr\\u00e9 F\\u00e9lix\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/www.feltex.com.br\/felix\/#personlogo\",\"inLanguage\":\"pt-BR\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/d2d9cc82cab40245e6f803982b1448e6?s=96&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/d2d9cc82cab40245e6f803982b1448e6?s=96&r=g\",\"caption\":\"Andr\\u00e9 F\\u00e9lix\"},\"sameAs\":[\"http:\/\/www.feltex.com.br\"],\"url\":\"https:\/\/www.feltex.com.br\/felix\/author\/andre.felix\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Criando um Projeto Enterprise no Netbeans","description":"Criando um Projeto Enterprise no Netbeans","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/","og_locale":"pt_BR","og_type":"article","og_title":"Criando um Projeto Enterprise no Netbeans","og_description":"Criando um Projeto Enterprise no Netbeans","og_url":"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/","og_site_name":"Aprenda Java","article_publisher":"https:\/\/www.facebook.com\/feltex.br","article_published_time":"2014-05-02T15:09:41+00:00","article_modified_time":"2014-11-17T13:39:45+00:00","og_image":[{"url":"http:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-1.png"}],"twitter_misc":{"Escrito por":"Andr\u00e9 F\u00e9lix","Est. tempo de leitura":"8 minutos"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebSite","@id":"https:\/\/www.feltex.com.br\/felix\/#website","url":"https:\/\/www.feltex.com.br\/felix\/","name":"Aprenda Java","description":"Cursos de java, SQL e Engenharia de Software","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.feltex.com.br\/felix\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"pt-BR"},{"@type":"ImageObject","@id":"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/#primaryimage","inLanguage":"pt-BR","url":"http:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-1.png","contentUrl":"http:\/\/www.feltex.com.br\/felix\/wp-content\/uploads\/2014\/04\/Criando-um-Projeto-Enterprise-no-Netbeans-1.png"},{"@type":"WebPage","@id":"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/#webpage","url":"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/","name":"Criando um Projeto Enterprise no Netbeans","isPartOf":{"@id":"https:\/\/www.feltex.com.br\/felix\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/#primaryimage"},"datePublished":"2014-05-02T15:09:41+00:00","dateModified":"2014-11-17T13:39:45+00:00","author":{"@id":"https:\/\/www.feltex.com.br\/felix\/#\/schema\/person\/1e49f842c6254b4561b66ccf573c2069"},"description":"Criando um Projeto Enterprise no Netbeans","breadcrumb":{"@id":"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/#breadcrumb"},"inLanguage":"pt-BR","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.feltex.com.br\/felix\/criando-projeto-enterprise-netbeans\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Criando um Projeto Enterprise no Netbeans"}]},{"@type":"Person","@id":"https:\/\/www.feltex.com.br\/felix\/#\/schema\/person\/1e49f842c6254b4561b66ccf573c2069","name":"Andr\u00e9 F\u00e9lix","image":{"@type":"ImageObject","@id":"https:\/\/www.feltex.com.br\/felix\/#personlogo","inLanguage":"pt-BR","url":"https:\/\/secure.gravatar.com\/avatar\/d2d9cc82cab40245e6f803982b1448e6?s=96&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/d2d9cc82cab40245e6f803982b1448e6?s=96&r=g","caption":"Andr\u00e9 F\u00e9lix"},"sameAs":["http:\/\/www.feltex.com.br"],"url":"https:\/\/www.feltex.com.br\/felix\/author\/andre.felix\/"}]}},"_links":{"self":[{"href":"https:\/\/www.feltex.com.br\/felix\/wp-json\/wp\/v2\/posts\/594"}],"collection":[{"href":"https:\/\/www.feltex.com.br\/felix\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.feltex.com.br\/felix\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.feltex.com.br\/felix\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.feltex.com.br\/felix\/wp-json\/wp\/v2\/comments?post=594"}],"version-history":[{"count":10,"href":"https:\/\/www.feltex.com.br\/felix\/wp-json\/wp\/v2\/posts\/594\/revisions"}],"predecessor-version":[{"id":1611,"href":"https:\/\/www.feltex.com.br\/felix\/wp-json\/wp\/v2\/posts\/594\/revisions\/1611"}],"wp:attachment":[{"href":"https:\/\/www.feltex.com.br\/felix\/wp-json\/wp\/v2\/media?parent=594"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.feltex.com.br\/felix\/wp-json\/wp\/v2\/categories?post=594"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.feltex.com.br\/felix\/wp-json\/wp\/v2\/tags?post=594"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}