Jsp using mvc

Jsp using mvc

View Answers

December 17, 2008 at 5:58 AM

Hi friend,

1). Model: The model object knows about all the data that need to be displayed. It is model who is aware about all the operations that can be applied to transform that object. It only represents the data of an application. The model represents enterprise data and the business rules that govern access to and updates of this data. Model is not aware about the presentation data and how that data will be displayed to the browser.

2). View : The view represents the presentation of the application. The view object refers to the model. It uses the query methods of the model to obtain the contents and renders it. The view is not dependent on the application logic. It remains same if there is any modification in the business logic. In other words, we can say that it is the responsibility of the of the view's to maintain the consistency in its presentation when the model changes.

1. The MVC2 architecture removes the page centric property of MVC1 architecture by separating Presentation, control logic and the application state.
2. In MVC2 architecture there is only one controller which receives all the request for the application and is responsible for taking appropriate action in response to each request.



3). Controller: Whenever the user sends a request for something then it always go through the controller. The controller is responsible for intercepting the requests from view and passes it to the model for the appropriate action. After the action has been taken on the data, the controller is responsible for directing the appropriate view to the user. In GUIs, the views and the controllers often work very closely together.


Read MVC 2 Pattern in Struts2 in details and visit to :

http://www.roseindia.net/struts

Thanks









Related Tutorials/Questions & Answers:
Jsp using mvc - JSP-Servlet
Jsp using mvc  hi I have written using mvc2 architecture, i have written logic in java ,i want to print a message on the form stating the the values... closely together. Read MVC 2 Pattern in Struts2 in details and visit
using jsp and servlets andin Mvc architecture
using jsp and servlets andin Mvc architecture  how to insert a form data in different tables, that means education details in education table, address details in address table,like that and finally if we fetch all must come
Advertisements
save multiple records into database using jsp/servlet mvc
save multiple records into database using jsp/servlet mvc  hai, this is my jsp where i have enter multiple username and password and save...   hai friend, thank u, using string[] i did tat its workg fine
Upload Image and save in database using jsp-servlet mvc
Upload Image and save in database using jsp-servlet mvc  Here is my code.. In jsp ... <form name=frm method="post" action="Device"> <table> <tr><TD ><B>Upload Image</B><
Upload Image and save in database using jsp-servlet mvc
Upload Image and save in database using jsp-servlet mvc  Here is my code.. In jsp ... <form name=frm method="post" action="Device"> <table> <tr><TD ><B>Upload Image</B><
role of JSP in MVC
role of JSP in MVC  What is the role of JSP in MVC Model?   JSP is mostly used to develop the user interface, It plays are role of View in the MVC Model
About MVC 2 architecture and jsp - JSP-Servlet
About MVC 2 architecture and jsp  Sir, I want to know about MVC 2... is the need of servlets when jsp can perform all functionalities .  Hi Friend, JSP and Servlets both are the server side components which can respond
How to validate form using Spring MVC?
How to validate form using Spring MVC?  Hi, I want to validate a form in Spring MVC using the annotation. How to validate a form in Spring MVC. I... to validate form using Spring MVC? How to use annotation for validation? Thanks
spring mvc configuration with mysql using jdbc
spring mvc configuration with mysql using jdbc  hai I want to configure web mvc with mysql using jdbc template. when I submit values using registration form it will reflect on database which i was created earlier. send me code
Is JSF using JSP?
Is JSF using JSP?  Is JSF using JSP
Autocomplete textbox with database in jsp and follow the MVC model
Autocomplete textbox with database in jsp and follow the MVC model  i... with database mysql follow MVC Model but it not perform. So please Help me sir... Thanks in advance  Here is a jsp code that shows autocomplete box
tree using jsp code
tree using jsp code  i want to draw a tree structure of a family hierarchy using jsp code
report generation using jsp
report generation using jsp  report generation coding using jsp
mvc
mvc  I want MVC example using jsp,servlets,pojoclass,jdbc(with mysql)..operation of insert,search,delete,update. I want above web application only... get only jsp servlets web application from your website & some other links. so
online book store by using MVC architecture
online book store by using MVC architecture  Tarzan book store decided to go online to increase itsā?? revenues and provide itsā?? customers a way... and servlets The application needs to be built in J2EE and complaint with MVC
A Java Program by using JSP
A Java Program by using JSP  how to draw lines by using JSP plz show me the solution by using program
generate charts using JSP
generate charts using JSP  any one know coding for generate bar chart or pie chart using JSP
ScatterPlot using jsp
ScatterPlot using jsp  hi, can anybody provide me code for ScatterPlot using jsp. thanks
datasource in jsp using struts
datasource in jsp using struts  how to get the datasource object in jsp.datasource is configured in struts-config.xml
BMI by using JSP Languange
BMI by using JSP Languange  Using JSP language, create a system that calculates Body Mass Index (BMI) of users who entered their weight and height. Then, system will display all the records. Can you provide me the coding
BMI by using JSP Languange
BMI by using JSP Languange  Using JSP language, create a system that calculates Body Mass Index (BMI) of users who entered their weight and height. Then, system will display all the records. Can you provide me the coding
video uploading using jsp
video uploading using jsp  how to upload a videos in web page using jsp   Hi, You can upload your video with the help of JSP file upload code. Once file is upload you can play using any video player. Get the code
Using Scriplet in JSP - JSP-Servlet
on } IN HOME JSP ****** home.jsp **** Currently I am directly using...Using Scriplet in JSP  Hi, I need to display suitable fields in my jsp but this should be done upon suitable condition becomes true for eg
Spring MVC and Hibernate with DWR 3 -- Configuration Using MySQL Database
Spring MVC and Hibernate with DWR 3 -- Configuration Using MySQL Database  How to configure Spring MVC and Hibernate with DWR 3, Simple example -- reading a table, editing-deleting and adding new rows
using jsp's....and ajax - Ajax
using jsp's....and ajax  Hi, i need code using ajax .....in a text box when i enter an alphabet i should get list of words starts with the alphabet given in the text box
generate pdf using jsp
generate pdf using jsp  how do i generate a pdf using jsp that should query the data from the database and write it into a pdf and download the same
jsp using netbeans
jsp using netbeans  Code to access and manage multiple e-mail accounts on the same page.. user should be able to edit mail accounts' link as required
barcode reader using jsp
barcode reader using jsp  HI ALL, I need jsp code for barcode reader.When we scan the barcode image that barcode value will be stored in one textbox automatically. please helpe me. Regards Bhanu
Tiemsheet using jsp
Tiemsheet using jsp  Hi, I am working on creating timesheet using JSP. Can you please help me on how to create a timesheet in excel using jsp and users should fill the excel sheet and then on submitting it should uplaod excel
sending mail using jsp
sending mail using jsp  please give me the detailed procedure and code for sending mail through jsp program   Please visit the following links: http://www.roseindia.net/ejb/introduction/j2eedemo.shtml http
Concept of subqueires using JSP
Concept of subqueires using JSP  Can I implement the concept of sub queries in JSP page , if yes please tell me how this can be achieved. I have requirement where output of the SQL query should be given as input to the update
display image using jsp
display image using jsp  display image using jsp and phonegap on emulator of eclipse   Here is a simple jsp code that displays an image on browser. <%@ page import="java.io.*" %> <%@page contentType="image/gif
emailing using jsp
emailing using jsp  hi there!! i have some difficulty in sending email using jsp. basically, i have an account table that retrieve all the account from the account-table in my ms sql database. so whenever i deleted the account
jsp using include & with mysql
jsp using include & with mysql  Sir, I am creating a login application using jsp & Mysql. The Codes are--- Html File...... <...; Jsp file....... <%@ page import="java.sql.*" %> <% String
How a simple "Hello World" can be displayed using Spring 3.2 MVC?
How a simple "Hello World" can be displayed using Spring 3.2 MVC?  Hi, How a simple "Hello World" can be displayed using Spring 3.2 MVC? Thanks... World using spring 3.2 MVC we need to configuration of spring MVC that as given
jsp using Beans
jsp using Beans  public class Empbean { int empno; String ename... need jsp program for above bean class   Hi Friend, Try the following...); RequestDispatcher rd = req.getRequestDispatcher("/jsp/beandata.jsp"); rd.forward
MVC Example
MVC Example  I WANT MVC EXAMPLE PROGRAM using Jsp Servlets and Jdbc with mysql of Insert,update,delete,search. please give the answer in MVC rule
Uploading image using jsp
Uploading image using jsp  how to upload image using jsp. Already i... that image file ... I want know that solution using by u... Thanks, P.S.N.   Here is a jsp code that upload image and display it on the browser. 1
JSP using java - Hibernate
JSP using java  This is my part of Excal sheet code using jdbc connection. int index=1; while(rs.next... using hibernate.I am having function called displayIps() and displayvalues
jsp page authentication panel using jsp/servlet?
jsp page authentication panel using jsp/servlet?  I have 10 jsp jsp forms and 7 users and i want to grant variour permission like edit,delete and save for users dynamically on forms.So please refer me code
how to create using jsp
how to create using jsp  code 1: <%@ page language="java...;%=request.getContextPath()%>/jsp/Create.jsp">Create</a> </p> <p><a href="<%=request.getContextPath()%>/jsp/View.jsp">View </a>
file upload using JSP
file upload using JSP  I have created a form to upload a file in a html page, now i want to get the path of the file in a jsp page so what code should I write? thanks and regards...   1)page.jsp: <%@ page language
how can i prevent duplicate records using servlets and MVC model?
how can i prevent duplicate records using servlets and MVC model?  hai, I need a program to insert values into database at the same time it shows... want this program in MVC model.can anyone help me... Thanks&Regards P.Divya
image upload&download using jsp - JSP-Servlet
image upload&download using jsp  can any one help in writing jsp... visit the following links: http://www.roseindia.net/jsp/fileupload.shtml http://www.roseindia.net/jsp/downloadimage.shtml Hope that the above links
Displaying image using jsp and spring.
Displaying image using jsp and spring.  how to display an image stored in WEB-INF/images folder on the browser using jsp and spring
ajax using jsp
ajax using jsp  <%@ page import="java.io.*" %> <%@ page import="java.util.*" %> <%@ page import="java.sql.*" %> <%@ page import="java.util.StringTokenizer" %> <%@ page import="java.lang.*" %> <
create using jsp
create using jsp  code 1:``<%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%> <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org
Ajax using jsp
Ajax using jsp  <%@ page import="java.io.*" %> <%@ page import="java.util.*" %> <%@ page import="java.sql.*" %> <%@ page import="java.util.StringTokenizer" %> <%@ page import="java.lang.*" %> <
video uploading using jsp
video uploading using jsp  this is the code i hv written for uploading..but the value in dropdown list is not captured..can any 1 tell the reason html file <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN
file uploading using jsp
file uploading using jsp  below file uploading code has one error "toBytes[i-start]=fromBytes; " incompatable type error please help me how to solve this error &lt;%@ page import="java.io.

Ads