When I import the Controller annotation into Spring, the following error appears:
The import org.springframework.stereotype.Controller conflicts with a type defined in the same file
Here is the (very simple) code of my web-MVC startup project:
package com.company.project.servlet; import org.springframework.stereotype.Controller; @Controller public class Controller { public String execute(){ System.out.println("Controller executing..."); return("page"); } }
As you can see, there is no reason for the error to be shown here. Do you have any ideas on what is going to happen? Thanks!
Useful information: - Eclipse Spring Tool Suite 3.3.0 (above Kepler) - Eclipse jars version 4.0.0.M1 (These should be the best versions of all this)
source share