Replace String literals with MediaType constants
MSALReplace String literals with org.springframework.http.MediaType constants in modules that depend on spring-web.
org. openrewrite. java. spring. http. ReplaceStringLiteralsWithMediaTypeConstantsmod run . --recipe= org. openrewrite. java. spring. http. ReplaceStringLiteralsWithMediaTypeConstantsInstall it once from Recipe actions, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.
Recipe list
It runs these recipes, in this order.
- Replace String literal with constant
org.springframework.http.MediaType.ALL_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_ATOM_XML_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_CBOR_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_FORM_URLENCODED_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_GRAPHQL_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_GRAPHQL_RESPONSE_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_JSON_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_JSON_UTF8_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_OCTET_STREAM_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_PDF_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_PROBLEM_JSON_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_PROBLEM_JSON_UTF8_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_PROBLEM_XML_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_PROTOBUF_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_RSS_XML_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_NDJSON_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_STREAM_JSON_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_XHTML_XML_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_XML_VALUE - Replace String literal with constant
org.springframework.http.MediaType.APPLICATION_YAML_VALUE - Replace String literal with constant
org.springframework.http.MediaType.IMAGE_GIF_VALUE - Replace String literal with constant
org.springframework.http.MediaType.IMAGE_JPEG_VALUE - Replace String literal with constant
org.springframework.http.MediaType.IMAGE_PNG_VALUE - Replace String literal with constant
org.springframework.http.MediaType.MULTIPART_FORM_DATA_VALUE - Replace String literal with constant
org.springframework.http.MediaType.MULTIPART_MIXED_VALUE - Replace String literal with constant
org.springframework.http.MediaType.MULTIPART_RELATED_VALUE - Replace String literal with constant
org.springframework.http.MediaType.TEXT_EVENT_STREAM_VALUE - Replace String literal with constant
org.springframework.http.MediaType.TEXT_HTML_VALUE - Replace String literal with constant
org.springframework.http.MediaType.TEXT_MARKDOWN_VALUE - Replace String literal with constant
org.springframework.http.MediaType.TEXT_PLAIN_VALUE - Replace String literal with constant
org.springframework.http.MediaType.TEXT_XML_VALUE