com.mangofactory.swagger.core
Interface ResourceGroupingStrategy

All Known Implementing Classes:
ClassOrApiAnnotationResourceGrouping, SpringGroupingStrategy

public interface ResourceGroupingStrategy


Method Summary
 java.lang.String getResourceDescription(org.springframework.web.servlet.mvc.method.RequestMappingInfo requestMappingInfo, org.springframework.web.method.HandlerMethod handlerMethod)
          Gets the resource description.
 java.util.Set<ResourceGroup> getResourceGroups(org.springframework.web.servlet.mvc.method.RequestMappingInfo requestMappingInfo, org.springframework.web.method.HandlerMethod handlerMethod)
          Gets the resource group for a particular request mapping.
 java.lang.Integer getResourcePosition(org.springframework.web.servlet.mvc.method.RequestMappingInfo requestMappingInfo, org.springframework.web.method.HandlerMethod handlerMethod)
          Gets the position of the resource.
 

Method Detail

getResourceGroups

java.util.Set<ResourceGroup> getResourceGroups(org.springframework.web.servlet.mvc.method.RequestMappingInfo requestMappingInfo,
                                               org.springframework.web.method.HandlerMethod handlerMethod)
Gets the resource group for a particular request mapping. Typically several requestMappings will live under a particular resource group.

Parameters:
requestMappingInfo - request mapping info
handlerMethod - handler method
Returns:
Resource group uris.
See Also:
ApiListingReferenceScanner

getResourceDescription

java.lang.String getResourceDescription(org.springframework.web.servlet.mvc.method.RequestMappingInfo requestMappingInfo,
                                        org.springframework.web.method.HandlerMethod handlerMethod)
Gets the resource description. i.e. the top level resource name for a set of api operations as displayed on the main swagger ui page. e.g. 'BusinessApiController' This is typically the class name of the spring controller or value() attribute of any @Api annotations on that controller class

Parameters:
requestMappingInfo - request mapping info
handlerMethod - handler method
Returns:
description of the resource

getResourcePosition

java.lang.Integer getResourcePosition(org.springframework.web.servlet.mvc.method.RequestMappingInfo requestMappingInfo,
                                      org.springframework.web.method.HandlerMethod handlerMethod)
Gets the position of the resource. Typically com.wordnik.swagger.annotations.Api.position

Parameters:
requestMappingInfo -
handlerMethod -
Returns:
The numeric position