@ Override public List < String > contentTypes ( ) { List < String > contentTypes = null ; final HttpServletRequest request = getHttpRequest ( ) ; if ( favorParameterOverAcceptHeader ) { contentTypes = getFavoredParameterValueAsList ( request ) ; } else { contentTypes = getAcceptHeaderValues ( request ) ; } if ( isEmpty ( contentTypes ) ) { logger . debug ( "Setting content types to default: {}." , DEFAULT_SUPPORTED_CONTENT_TYPES ) ; contentTypes = DEFAULT_SUPPORTED_CONTENT_TYPES ; } return unmodifiableList ( contentTypes ) ; }
Returns requested content types or default content type if none found .