Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / New
Stats: 3,150,289 members, 7,807,981 topics. Date: Thursday, 25 April 2024 at 01:10 AM

Web Development Using Java - Programming - Nairaland

Nairaland Forum / Science/Technology / Programming / Web Development Using Java (5438 Views)

How To Create A Simple Calculator Using Java Programing Language GUI / Web Service Using Java Or C# / Web Development Using PHP (2) (3) (4)

(1) (Reply) (Go Down)

Web Development Using Java by sbucareer(f): 1:48pm On Jan 18, 2006

Do we still have developers using JSP, Servlets and strut for Web development? And do Nigerians use any reference container for Java i.e. jakarta tomcat
Re: Web Development Using Java by sbucareer(f): 1:52pm On Jan 18, 2006

All I hear is php, asp, php, asp!!!  Do we have any web host companies that support Java.  To learn more about java visit Sun Java, Java forum

Re: Web Development Using Java by Viper(m): 6:34pm On Feb 27, 2006
REGARDING WEBHOSTS, there are many that support JEE.
also, with respect to companies in nigeria using JEE, i would say that the top IT companies in naija(lagos especially)are using the java technology seriously now.
Even those that were using other technologies like Coldfusion,vb and other ones are now migrating to the java platform.
Re: Web Development Using Java by sbucareer(f): 8:29pm On Feb 27, 2006

Good work Viper
Re: Web Development Using Java by mimohmi(m): 3:00am On Mar 06, 2006
Viper pls can you tell me some of these companies ?
Re: Web Development Using Java by mimohmi(m): 3:19am On Mar 06, 2006
Hi sbucareer,
Long time. Well thanks for your advice. Have been getting my hands real dirty with EJB and related technologies. Hope to hit
the SCBCD exams by this weekend and may be web service next.
On the java issue, most guys down here strongly feel java is out of place, and i think the problem has to do with the standard of
available training facilities. Most guys i know complain of java been slow. But take a look at the improvement from java 1.4 to 5.0(Tiger)
and the new 6.0(Mustang), it can match any other language. I think we need a place people in Nigeria, not NIIT and Aptech, where people
can learn Java.
Re: Web Development Using Java by Viper(m): 11:38am On Mar 06, 2006
Well mimoh,
i can say some top IT companies in lagos like systemspecs, etranzact, csa and even vmobile use java technologies to run most of thier applications.

good to hear that u gunning @ the scbcd exams, which prometric centre are u going to write it?
and how much do they place the cost @?
Re: Web Development Using Java by sbucareer(f): 2:46pm On Mar 06, 2006


mimoh_mi, good luck in your exam. I would also consider that you completely master and understand this tutorial. It has been there for a while and most of the tools used are out dated. I used it in 2003 when I was preparing for my SCEA exams. These are the tools that I used. I used EJB 2.0, Sun Application Server 8.1 RI, Netbeans 4.1 beta.

The tools I used are old now and I believe they have newer versions now. The tutorial used JBoss and Lomboz and eclipse, you do not have to use their tools. If you have studies enough to take SCBCD, you should be able to understand the tutorial. Certification is one thing experience is another. When you go to the interview, your skills, certs and practical experience would never let you down.

If you have problem setting up this environment let know I will give you some help.  Good luck

NB
----------

Remember now that Sun Application Sever PE 8.2 is out now and uses EJB 3.0, JSP 3.0, JSF 2.0 and many more middleware technologies. You can download the Application server differently and download any IDE of your choice separately. I use Sun Enterprise Studio with Oracle 10g for my databasee access. I used OC4j.jar ([b]O[/b]ra[b]c[/b]le 4 [b]J[/b]ava)  for my database driver.

Configure your ODBC and database connector using JNDI in the application server and call that object in your application middleware.  In J2EE NEVER use database API in the front side. Employ MVC. All your database routine should be writen in DAO (Data Access Object), it is a java file, call your beans to access session or Entity beans either BMP, CMP using either stateless or stateful persistent.

Have your JSP listen to a single servlet that handles all the request and response to the HTTP UI ie. HTML. You can also use it to listen to Standalone client (FAT Client).

My sun example and Controller UML also see J2EE front controller
Re: Web Development Using Java by mimohmi(m): 11:33pm On Mar 06, 2006
Thanks for the links. All the same. i hope to work on a project after my exams. Presently, am using the Sun App Server 9.0 (Beta) and Java EE 5.
Lot of differences in terms of development and deployment and the support for web service. I strongly believe that sooner or later, one will need to upgrade. So my target is for the beta version of the exam and a way of keeping myself updated with current development in java. For a design pattarn, am roughing my hands and head out with Struts 1.2.8. As you know it's just a glorified Front Controller.
More gist after my exams
Re: Web Development Using Java by sbucareer(f): 11:37am On Mar 07, 2006

Yeah!!!, good luck and I hope you come out with flying colors. Tell us about your experience, the center, how much it cost you and etc.?

I will like to keep you informed with J2EE, Java technologies and design pattern.  We are using BPEL (Business Process Execution Language) and JAF (Java Activation Framework) at my work place. JAF works with JSF (Java Server Faces).  Many company nowadays use their own design pattern that suit there need. I will not say it here because it is a company property since I work for them. I am developing a design pattern that could be used with XML and be ported in HTML Syntax language.

Strut is very old and has many shortcomings, J2SE now comes with Tag API's so you can define your own framework. I dislike the ideas that I have to import my API's from a remote location i.e.

 
<%--
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
--%>

implementation

  <%--
    <c:if test="${param.sayHello}">
        <!-- Let's welcome the user ${param.name} -->
        Hello ${param.name}!
    </c:if>
    --%>


I had like to be in a situation where I can define my routines and API's and called them within my application. Anyway let keep intouch and brainstorm knowledge regarding Java technologies.

Re: Web Development Using Java by africanboy(m): 12:31pm On Mar 07, 2006
hey sbu, tried connecting wit u on yahoo, but wit problems. tried downloading jdk but 2 no avail, link me up with d guy u sent the cd to and maybe i could rip a copy from me.
Re: Web Development Using Java by bioye(m): 9:36pm On Mar 07, 2006
hi guys,

i am a java developer and it's good to see people talking java here.  one company that's doing very well with Java is SocketWorks.  And I know Globacom uses java heavily for their mobile solutions.  Some colleagues of mine were employed specifically for their java skills.

I specialise in Open Source Web Java.  My favourite framework is Tapestry.  I prefer it to JSF, Struts and WebWork.  And I use Tomcat and Jetty as my webserver.  I use Hibernate for Persistence.

Will keep my eye on these thread. Keep the coffee hot!.
Re: Web Development Using Java by mimohmi(m): 11:30pm On Mar 07, 2006
Hi africanboy,
Downloading the jdk could be stressful. The best way out is to use Sun Download Manager
rhttp://www.sun.com/download/sdm/index.xml,
as recommended by Sun. Install it. It's very easy to use. You can get jdk 5.0 from Sun's download center.
http://192.18.108.138/ECom/EComTicketServlet/BEGIN91AB276373D865C48A4D08360C002572/-21474648/1361497635/1/681986/681818/1361497635/2ts+/westCoastFSEND/jdk-1.5.0_06-oth-JPR/jdk-1.5.0_06-oth-JPR:2/jdk-1_5_0_06-windows-i586-p.exe
The latest version of jdk is 6.0 but it's still at beta stage. i don't advice you to go for it now. May be later. If you still have any problems, please let me know.

Bye for now
Re: Web Development Using Java by BashiBazoo: 4:30am On Mar 08, 2006
@sbucareer
I have been reading your java post on the forum and found them very interesting and useful. I have tried the http://www.tusc.com.au/tutorial/html/chap1.html tutorial you suggested.

I have installed eclipse, jboss and loaded the hsql database. However I am stuck at the Lomboz configuration. I am installing on windows XP with jboss-3.2.8.SP1, eclipse 3.1.2 (newer than what is at the tutorial which was written in 2003). I have gone to the http://sourceforge.net/projects/lomboz or from http://www.objectlearn.com/index.jsp site in the tutorial to try and get the Eclipse plug-in. For one thing I had so many to choose from, the one that actually had the com.objectlearn.jdt.j2ee directory after unzipping did not have a sub directory for "servers" in which the jboss321all.server should be placed.

I manually created this servers dir and cp the com.objectlearn.jdt.j2ee in there and placed in the plugin for eclipse but I could not see the option for "other" "lomboz" in the Customize Perspective window of Eclipse as directed

I have gone to some jboss forum and noticed a couple of people have this problem but no useful answers. Do you have any suggestions how I can configure Lomboz using jboss"321"all.server that will work with my version of eclipse?

Thanks!!
Re: Web Development Using Java by sbucareer(f): 6:02pm On Mar 18, 2006

I was wondering if developer in this forum that uses Java as their platform for developing web application or n-tier web application, is familiar with JSTL or JSF. What is JSTL or JSF?


The JavaServer Pages Standard Tag Library (JSTL), is a component of the Java EE Web application development platform. It extends the JSP specification by adding a tag library of JSP tags for common tasks, such as XML data processing, conditional execution, loops and internationalization. JSTL was developed under the Java Community Process (JCP) as JSR 52. As of 2006, the current version of JSTL is 1.1.

JSTL provides an effective way to embed logic within a JSP page without using embedded Java code directly. The use of a standardized tag set, rather than breaking in and out of Java code leads to more maintainable code and enables separation of concerns between the development of the application code and user interface.



While JSF is JavaServer Faces (JSF) is a Java-based Web application framework that simplifies the development of user interfaces for Java EE applications. Out of the box, JSF uses JavaServer Pages for its display technology, but JSF can also accommodate other display technologies, such as XUL, for example.


To use these technologies in the development process of a web application (Forms) we simple create a backing bean or JavaBeans. JavaBean is a reusable component that can be used in any Java application development environment. JavaBeans are dropped into an application container, such as a form, and can perform functions ranging from a simple animation to complex calculations.

These beans can connect to a datasource using either DAO (Data Access Object) or a JNDI (Java Naming and Directory Interface) The Java Naming and Directory InterfaceTM (JNDI) is a standard extension to the Java platform, providing Java-enabled applications with a unified interface to multiple naming and directory services in the enterprise.

A datasource is a logical name to a physical connection to a database using mapping technology found in JNDI. Many java web container have the configuration section to allow this process i.e Tomcat, BEA, IBM Webspere, Sun AppServ, WebLogic, JBoss etc. Look at a typical DAO connection to a database


/*
* StoreAccesDAO.java
*
* Created on 10 March 2006, 02:56
*
* To change this template, choose Tools | Template Manager
* and open the template in the editor.
*/

package ejb.dao;

/**
*
* @author Administrator
*/
public interface StoreAccesDAO {
   
    public String loginUser(String username, String passwd);
}




*
* StoreAccessDAOImp.java
*
* Created on 10 March 2006, 02:59
*
* To change this template, choose Tools | Template Manager
* and open the template in the editor.
*/

package ejb.dao;

import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import javax.naming.InitialContext;
import javax.sql.DataSource;

/**
*
* @author Administrator
*/
public class StoreAccessDAOImp implements StoreAccesDAO{
   
    DataSource jdbcFactory;
   
    /** Creates a new instance of StoreAccessDAOImp */
    public StoreAccessDAOImp() {
       
        InitialContext cxt =null;
        if(jdbcFactory == null ){
            try{
                jdbcFactory = (DataSource) cxt.lookup("java:comp/env/jdbc/mysql"wink;
            }catch(Exception e){
               e.getMessage();
            }//End catch
        }//End if
    }//End StoreAccesDAOImp
   
    public String loginUser(String username, String passwd){
       
        Connection con = null;
        PreparedStatement stmt = null;
        ResultSet rs = null;
        String userId = null;
        boolean result;
        String query ="select from storeaccess where username=? and password=? ";
       
        try{
            con = jdbcFactory.getConnection();
            stmt = con.prepareStatement(query);
            stmt.setString (1, username);
            stmt.setString(2, passwd);
            rs = stmt.executeQuery ();
            result = rs.next();
           
            if(result){
                userId = rs.getString("userid"wink;
            }//End if
           
        }catch(Exception e){
            e.getMessage();
        }//End catch
       
        finally{
            try{
                con.close();
                stmt.close();
                rs.close();
            }catch(Exception e){
                e.getMessage();
            }
        }
        return userId;
       
    }//End loginUser
}


Now in the web tier, we can call this backing bean like this


<%@page contentType="text/html"%>
<%@page pageEncoding="UTF-8"%>

<%--
The taglib directive below imports the JSTL library. If you uncomment it,
you must also add the JSTL library to the project. The Add Library,  action
on Libraries node in Projects view can be used to add the JSTL 1.1 library.
--%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %> 
<f:loadBundle basename="bundle.Messages" var="Message"/>
<jsp:useBean scope="request" id="demo" class="ejb.dao.StoreAccessDAOImp"/>



<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
   "http://www.w3.org/TR/html4/loose.dtd">

<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>Digitemsystems Online Banking</title>
    </head>
    <body>

    <h1>Online Banking</h1>
   
     <f:view>
        <h:form id="form1">
            <h:outputText value="#{Message.username}" />
            <h:inputText id="username" value="#{demo.username}" required="true">
                <f:validateLength minimum="2" maximum="10"/>
            </h:inputText>
            <h:outputText value="#{Message.password}" />
            <h:inputText id="passwd" value="#{demo.password}" required="true">
                <f:validateLength minimum="2" maximum="10"/>
            </h:inputText>
           
            <h:commandButton id="submit" action="" value="login"/>
        </h:form>
    </f:view>
         
    </body>
</html>


It is very rewording to program Business application in this form. It is modular and provide someone without knowledge of java to work in the front-end system without knowing what is happening in the beans side.

Loose coupling is the key to any software development. If the back-end function changes for any reason the front tier do not necessary need to change as it is relational Mapping using JNDI and other front-end framework like JSF and JSTL.
Re: Web Development Using Java by mimohmi(m): 12:14am On Mar 22, 2006
Finally downloaded the Sun Studio, pretty cool. Make developing web client easier.
Please can you give me links to JSF tutorials. Thanks
Re: Web Development Using Java by sbucareer(f): 1:19am On Mar 22, 2006

JSTL I prefer JSTL to JSF, don't ask me why as you would soon find out why.

Re: Web Development Using Java by alexis(m): 9:46pm On Mar 28, 2006
Nice thread,

I am still command lining with java but hey - I am loving it. I have no experience with jsp but I do know it rocks. I designed the dbase structure for the one of the best GSM companies that run their SMS portal on jsp in Ghana, check it out.

www.tigo.com.gh

I know this girl coder that coded the whole thing in jsp - she is amazingly intelligent
Re: Web Development Using Java by sbucareer(f): 10:14am On Mar 29, 2006

Alexis, if you are still in contact with this girls ask her to come and visit Niaraland.com. I would love to meet her. She is very skillful if she was the one that designed that website.

I would be coming to Ghana ending of April, I am conducting a research in Ghana and propably setup an IT business in Ghana. If successful, I would not mind to employ her for Java web application consultations.

Re: Web Development Using Java by alexis(m): 9:54pm On Mar 29, 2006
Ok man - I will contact her, she works for a dutch programming firm here, I will give you details as soon as I get in touch with her. By the way - do you have any nice tutorials on jsp?

Ghana aint bad but it's quite expensive though. They have a few good software companies here but most of them are into VB. The good guys using java are outside the country.
Re: Web Development Using Java by sbucareer(f): 9:55am On Mar 30, 2006

Alexis, thanks. Regarding JSP materials, I use Wrox textbooks a lot i.e. Professional Java Server Programming ISBN 1-861002-77-7, Beginning JSP Web Development ISBN 1-861002-09-2, for EJB and J2EE search wrox.

JSTL and JSF, I use Oreilly books and they also provide online example and tutorial.  You can do google search

The new people I am trying their books are the digital gurus. I am still reading their JEE 5 and so far so good. You can try it yourself but I have not finished it so could not give you my thumbs-up.

Re: Web Development Using Java by alexis(m): 11:55am On Mar 30, 2006
thanks man - I have a few wrox books myself, on PHP and dotnetnuke. I will make sure I get the JSP books but I read an article that it is good you learn java before learning jsp because jsp is all java, is that true?
Re: Web Development Using Java by mimohmi(m): 2:00am On Mar 31, 2006
Hey sub,
Out of the blue again. I am working on a project(personal), the aim is to develop a java web app that can be plug into say
any site to carry out survey. The first page should be populated with a database supplied data and should consist of questions
and answers. eg

Q1 Rate my services
A1 Excellent Very Good Good Poor (Radio buttons)

So I created a survey database(mysql)

Tables
SurveyQuestions
id (pk)
name
question
SurveyResult
id(fk)
surveyOptions
valueCount


in my jsp as shown below;


<%@page contentType="text/html"%>
<%@page pageEncoding="UTF-8"%>
<%--
The taglib directive below imports the JSTL library. If you uncomment it,
you must also add the JSTL library to the project. The Add Library, action
on Libraries node in Projects view can be used to add the JSTL 1.1 library.
--%>
<%--
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
--%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="sql" uri="http://java.sun.com/jsp/jstl/sql" %>
<%@ page isELIgnored="false" %>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JSP Page</title>
</head>
<body>

<h1>JSP Page</h1>


<!--
This sql code returns to two row with multiple columns.
--->
<sql:query var="quest" dataSource="jdbc/SurveyDBF">
SELECT surveyquestion.question,surveyResult.surveyoption
from surveyquestion, surveyResult where surveyquestion.id and
surveyResult.id
</sql:query>

<!--
Now, want to loop through the result of the sql code to display a pair of question and line
and got hook. Help
-->
<table border=0>

</tr>

<tr>

<td>

<c:forEach var="row" items="${quest.rows}">
<input name="nono" type ="radio"/><c:out value="${row.Surveyoption}" />

</c:forEach>
</td></tr>
</table>

</body>
</html>
Re: Web Development Using Java by sbucareer(f): 11:44am On Apr 05, 2006

mimoh_mi, good to hear from you again. I have been of the forum for like 3 to 4 days now. Just got back! Fantastic, you are doing some personal project? I hope you already have some plan of marketing it? For what it is worth, it would be a delta experience.

I have looked at your code and it looks alpha, but I was thinking using DB this way will not scale very well in production site. Why don't you use Session Beans rather to Entity beans.  You know only entity beans talks to DB. Session beans talk to entity beans.

In your Session bean use stateless and employ Java API Vector, Collection to store the session states. Then use Iterator to look through your objects and provide a button to commit or destroy the state. When the commit is click then the Stateless bean will transfer the object(s) to entity bean(s) for DB persistent.

This will not only help your application with load-balancing and scalability, it would take of the processing power needed to handle every request as an entity transactions.

If you ask me I will not use DB on this project. I will use XML and employ SAX Simple API for XML or any other API for XML, lots of them. That would allow easy deployment at client site.

Let us know your progress.

Re: Web Development Using Java by sbucareer(f): 11:50am On Apr 05, 2006

I forgot this, never use SQL statement in the front-end. Use Beans helpper classes to wrap up all the SQL statements. Another way is to use Stateful Session beans. Very bad idea to use SQL in front-end. How about a web designer who do not know SQL and is employ to maintain you web apps? Above all, it breaks the golden rule of modularity.

Remember J2EE specifications for developing distributed application

1. All web application i.e. jsp, html, jsfl, *.gif, applets, web.configuration-files  depolyed into WAR ([b]W[/b]eb [b]Ar[/b]chive)
2. All beans application i.e. *.java sun.configurations and xml-configurations deployed into JAR ([b]J[/b]ava [b]A[/b]rchive)
3. All the J2EE components i.e. WAR and JAR deployed into EAR ([b]E[/b]nterprise [b]Ar[/b]chive)

When I am less busy I will show you a simple application using this paradigm.
Re: Web Development Using Java by sbucareer(f): 12:10pm On Apr 05, 2006

Look at a loginUser example using Stateless session bean in J2EE environment. I do not need to explain all the classes involved as you will have already known that since you are SCJP 1.4 SCJA (Beta) SCWCD 1.4 SCBCD 1.3

This is DAO objects Data Access Object session bean helpper classes

//*
* StoreAccesDAO.java
*
* Created on 10 March 2006, 02:56
*
* To change this template, choose Tools | Template Manager
* and open the template in the editor.
*/

package ejb.dao;

/**
*
* @author Administrator
*/
public interface StoreAccesDAO {
   
    public String loginUser(String username, String passwd);
}






/*
* CustomerDAOImp.java
*
* Created on 10 March 2006, 13:34
*
* To change this template, choose Tools | Template Manager
* and open the template in the editor.
*/

package ejb.dao;

/**
*
* @author Administrator
*/
public class CustomerDAOImp {
   
    /** Creates a new instance of CustomerDAOImp */
    public CustomerDAOImp() {
    }
   
}





/*
* StoreAccessDAOImp.java
*
* Created on 10 March 2006, 02:59
*
* To change this template, choose Tools | Template Manager
* and open the template in the editor.
*/

package ejb.dao;

import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import javax.naming.InitialContext;
import javax.sql.DataSource;

/**
*
* @author Administrator
*/
public class StoreAccessDAOImp implements StoreAccesDAO{
   
    DataSource jdbcFactory;
   
    /** Creates a new instance of StoreAccessDAOImp */
    public StoreAccessDAOImp() {
       
        InitialContext cxt =null;
        if(jdbcFactory == null ){
            try{
                jdbcFactory = (DataSource) cxt.lookup("java:comp/env/jdbc/mysql"wink;
            }catch(Exception e){
               e.getMessage();
            }//End catch
        }//End if
    }//End StoreAccesDAOImp
   
    public String loginUser(String username, String passwd){
       
        Connection con = null;
        PreparedStatement stmt = null;
        ResultSet rs = null;
        String userId = null;
        boolean result;
        String query ="select from storeaccess where username=? and password=? ";
       
        try{
            con = jdbcFactory.getConnection();
            stmt = con.prepareStatement(query);
            stmt.setString (1, username);
            stmt.setString(2, passwd);
            rs = stmt.executeQuery ();
            result = rs.next();
           
            if(result){
                userId = rs.getString("userid"wink;
            }//End if
           
        }catch(Exception e){
            e.getMessage();
        }//End catch
       
        finally{
            try{
                con.close();
                stmt.close();
                rs.close();
            }catch(Exception e){
                e.getMessage();
            }
        }
        return userId;
       
    }//End loginUser
}


Now these objects are called into the statelessBean i.e.


package ejbSession;

import java.rmi.RemoteException;
import javax.ejb.*;

/**
* This is the bean class for the StoreAccessBean enterprise bean.
* Created 09-Mar-2006 22:59:20
* @author Administrator
*/
public class StoreAccessBean implements SessionBean, StoreAccessRemoteBusiness {
    private SessionContext context;
    private ejb.dao.StoreAccesDAO dao = null;
   
 
    public void setSessionContext(SessionContext aContext) {
        context = aContext;
    }
   
    /**
     * @see javax.ejb.SessionBean#ejbActivate()
     */
    public void ejbActivate() {
       
    }
   
    /**
     * @see javax.ejb.SessionBean#ejbPassivate()
     */
    public void ejbPassivate() {
       
    }
   
    /**
     * @see javax.ejb.SessionBean#ejbRemove()
     */
    public void ejbRemove() {
       
    }
   
   

    public void ejbCreate() {
     
    }

    public String loginUser(String username, String passwd)throws RemoteException {
        dao.loginUser(username, passwd);
        return getDAO().loginUser(username, passwd);
    }
   
    protected ejb.dao.StoreAccesDAO getDAO(){
       
        if (dao != null){
            return dao;
        }else{
            dao =(ejb.dao.StoreAccesDAO) new ejb.dao.StoreAccessDAOImp();
            return dao;
        }//End if
    }//End getDAO
   
}






package ejbSession;

import java.rmi.RemoteException;
import javax.ejb.CreateException;
import javax.ejb.EJBHome;


/**
* This is the home interface for StoreAccess enterprise bean.
*/
public interface StoreAccessRemoteHome extends EJBHome {
   
    StoreAccessRemote create()  throws CreateException, RemoteException;
   
   
}






package ejbSession;


/**
* This is the business interface for StoreAccess enterprise bean.
*/
public interface StoreAccessRemoteBusiness {
   

    String loginUser(String username, String passwd) throws java.rmi.RemoteException;
}
     



package ejbSession;

import javax.ejb.EJBObject;


/**
* This is the remote interface for StoreAccess enterprise bean.
*/
public interface StoreAccessRemote extends EJBObject, StoreAccessRemoteBusiness {
   
   
}


Let me know if you do not understand it

Re: Web Development Using Java by Bossman(m): 7:31pm On Apr 13, 2006
A few posts back someone asked about some JSP resources. here is the book I use mostly of all the Servlets/JSP books I have. This, and also the WROX books are the ones I see at most sites that I have worked.

http://pdf.coreservlets.com/

Here is a very solid and free java book:

http://www.mindview.net/Books/TIJ/


Obviously, there are lots of good books out there. But, the above 2 are some of the best free books I have come accross.
Re: Web Development Using Java by talk2hb1(m): 7:31pm On Feb 02, 2018
sbucareer:


mimoh_mi, good luck in your exam. I would also consider that you completely master and understand this tutorial. It has been there for a while and most of the tools used are out dated. I used it in 2003 when I was preparing for my SCEA exams. These are the tools that I used. I used EJB 2.0, Sun Application Server 8.1 RI, Netbeans 4.1 beta.

The tools I used are old now and I believe they have newer versions now. The tutorial used JBoss and Lomboz and eclipse, you do not have to use their tools. If you have studies enough to take SCBCD, you should be able to understand the tutorial. Certification is one thing experience is another. When you go to the interview, your skills, certs and practical experience would never let you down.

If you have problem setting up this environment let know I will give you some help.  Good luck

NB
----------

Remember now that Sun Application Sever PE 8.2 is out now and uses EJB 3.0, JSP 3.0, JSF 2.0 and many more middleware technologies. You can download the Application server differently and download any IDE of your choice separately. I use Sun Enterprise Studio with Oracle 10g for my databasee access. I used OC4j.jar ([b]O[/b]ra[b]c[/b]le 4 [b]J[/b]ava)  for my database driver.

Configure your ODBC and database connector using JNDI in the application server and call that object in your application middleware.  In J2EE NEVER use database API in the front side. Employ MVC. All your database routine should be writen in DAO (Data Access Object), it is a java file, call your beans to access session or Entity beans either BMP, CMP using either stateless or stateful persistent.

Have your JSP listen to a single servlet that handles all the request and response to the HTTP UI ie. HTML. You can also use it to listen to Standalone client (FAT Client).

My sun example and Controller UML also see J2EE front controller
Nawa ooo

(1) (Reply)

Puzzle of the day / [problem] Write A Program In C++ That Finds The Hcf Of 2 Numbers Without Using A Recursive Function / How Much Does It Cost To Make An App?

(Go Up)

Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health
religion celebs tv-movies music-radio literature webmasters programming techmarket

Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10)

Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 127
Disclaimer: Every Nairaland member is solely responsible for anything that he/she posts or uploads on Nairaland.