1

Guava has a utility class for media type declarations (MediaType). However, it states in the Javadocs:

Note that this specifically does not represent the value of the MIME Content-Type header and as such has no support for header-specific considerations such as line folding and comments.

What does this mean? From what I can tell, the representation of media types is exactly the same as what's used in the Content-Type header. What will the problem be if I'm setting the Content-Type field using MediaType instances?

codebreaker
  • 699
  • 7
  • 22

1 Answers1

0

My guess is that as long as you're using some HTTP request API to set the Content-Type from the MediaType, you're fine, as that'll take care of any header-specific concerns.

ColinD
  • 103,631
  • 27
  • 195
  • 199