Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/java/380.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Java 使用SpringMVC通过URL访问静态方法_Java_Spring_Spring Mvc_Spring Roo - Fatal编程技术网

Java 使用SpringMVC通过URL访问静态方法

Java 使用SpringMVC通过URL访问静态方法,java,spring,spring-mvc,spring-roo,Java,Spring,Spring Mvc,Spring Roo,我有一个SpringRoo应用程序(它将SpringMVC用于脚手架视图),我想在访问特定URL时执行一个静态方法 我如何才能做到这一点?它与SpringRoo有什么关系。我认为它只适用于编译时,而不适用于运行时 在SpringMVC中,您可以创建一个@Controller,然后给出方法@RequestMapping(value=“/url”,method=RequestMethod.GET) 查看更多参考资料

我有一个SpringRoo应用程序(它将SpringMVC用于脚手架视图),我想在访问特定URL时执行一个静态方法


我如何才能做到这一点?

它与SpringRoo有什么关系。我认为它只适用于编译时,而不适用于运行时

在SpringMVC中,您可以创建一个@Controller,然后给出方法@RequestMapping(value=“/url”,method=RequestMethod.GET)

查看更多参考资料