Spring MVC Plugin API

Answered

Hello, 

I'm developing a plugin that requires to get all the Spring endpoints of the project (Which are in Spring > MVC Tab [Ultimate version]).

I know that Spring Plugin isn't open source, but I would like to know if there is any API that can retrieve the list of endpoints for my plugin?

0
3 comments

Hi, 

Sorry, but I can't find the method to get the list of endpoints of the project.

I've searched in spring.jar but couldn't find anything useful.

Could you please point me to the method?

0

hi,

What do you want to do with these endpoints?  

IJ-2019.3(community)  allows  to get all project endpoints (SpringMVC, Webflux, REST, etc.)  

for (UrlTargetInfo targetInfo : UrlResolverManager.INSTANCE.getCombinedResolver(project).getVariants()) {
String endpointText = targetInfo.getPath().toStringWithStars();
PsiElement psiDefinition = targetInfo.resolveToPsiElement();
}

it works for java and kotlin

0

Please sign in to leave a comment.