SSH框架项目总结

Struts1 

Action需要在文件中配置路径和path,在forward中加入映射的页面.

Action类要继承StrutsAction     在action 中加入 parameter="method" 路径加入对应的执行方法

  	
			
			
		
地址:localhost:8080/web/memberAction.do?method=execute1
如果需求中不需要路径中带有method方法

Action继承StrutsAction     默认执行execute()

Spring

配置文件读取


		
			
				classpath:db.properties
				classpath:common.properties
			
		
	
方便使用,已经装配到类中属性

		
			${jdbc.driver}
		
		
			${jdbc.url}
		
		
			${jdbc.username}
		
		
			${jdbc.password}
		
Spring bean 中注入


		   
		

你可能感兴趣的:(SSH框架项目总结)