HP Integrity NonStop H-Series User Manual

Page 103

Advertising
background image

Figure 5-13 New XML File: Options Dialog Box

The

EmpInfo-servlet.xml

file is created in the

EmpInfo/WebContent/WEB-INF

directory.

NOTE:

By default, XML files open in the XML Editor. The XML Editor has two views:

Design and Source view. Select the Source view.

5.

Modify the

EmpInfo-servlet.xml

file by adding a bean entry named

/insert.htm

and entering

com.hp.empinfo.web.EmployeeController

as its class.

NOTE:

The

com.hp.empinfo.web.EmployeeController

class provides controller

for the EmpInfo application to service a request according to its corresponding URL mapping
in

/insert.htm

. The Spring Web MVC framework uses an interface class called

HandlerMapping

to define the mapping between a request URL and the handler object,

which handles the request. The controller ensures that the URL mapping the EmpInfo
application is

com.hp.empinfo.web.EmployeeController

, instead of

DispatcherServlet

.

After modification, the

EmpInfo-servlet.xml

file appears as:

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:aop="http://www.springframework.org/schema/aop"
xmlns:p="http://www.springframework.org/schema/p"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:jee="http://www.springframework.org/schema/jee"
xmlns:tx="http://www.springframework.org/schema/tx"
xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
http://www.springframework.org/schema/context
http://www.springframework.org/schema/context/spring-context-2.5.xsd
http://www.springframework.org/schema/jee

Overview of EmpInfo

103

Advertising
This manual is related to the following products: