This commit is contained in:
lili 2016-09-08 09:05:40 +08:00
parent c66ba751a7
commit 6e68a67686
4 changed files with 21 additions and 11 deletions

View File

@ -2,11 +2,6 @@
<classpath>
<classpathentry kind="src" path="src"/>
<classpathentry kind="src" path="test"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/Java">
<attributes>
<attribute name="owner.project.facets" value="java"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.jst.server.core.container/org.eclipse.jst.server.tomcat.runtimeTarget/Apache Tomcat v7.0">
<attributes>
<attribute name="owner.project.facets" value="jst.web"/>
@ -14,5 +9,6 @@
</classpathentry>
<classpathentry kind="con" path="org.eclipse.jst.j2ee.internal.web.container"/>
<classpathentry kind="con" path="org.eclipse.jst.j2ee.internal.module.container"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="output" path="build/classes"/>
</classpath>

1
build/classes/.gitignore vendored Normal file
View File

@ -0,0 +1 @@
/com/

View File

@ -4,6 +4,7 @@ import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.ModelAndView;
@ -11,18 +12,30 @@ import com.platform.utils.Configs;
@Controller
public class DefaultController {
@RequestMapping("/")
public ModelAndView defaultHandler(HttpServletRequest req, HttpServletResponse res){
@RequestMapping("/tes")
public Object defaultHandler(HttpServletRequest req, HttpServletResponse request) {
//处理不匹配的请求
System.out.println("index");
return new ModelAndView("index");
try {
System.out.println("fsdfds");
return "listAll";
} catch (Exception e) {
e.printStackTrace();
return "result";
}
}
@RequestMapping("/test")
public void test(HttpServletRequest req, HttpServletResponse res){
public ModelMap test(HttpServletRequest req, HttpServletResponse res){
//System.out.println(Class.class.getClass().getResource("/").getPath());
System.out.println(Configs.EXTRACT_LOG_LOCALTION);
return new ModelMap();
}
}