char consumeCharacter(char c) {
            checkState(hasMore());
            checkState(previewChar() == c);
            position++;
            return c;
        }
Parses a media type from its string representation.

@throws IllegalArgumentException if the input is not parsable
core/src/main/java/com/linecorp/armeria/common/MediaType.java