MediaTypeCache (Apache Tomcat 6.0.51 API Documentation)
Keywords: org.apache.tomcat.util.http.parser.MediaTypeCache class

Overview | Package | Class | Tree | Deprecated | Index | Help
| Apache Tomcat 6.0.51
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.tomcat.util.http.parser
Class MediaTypeCache

    java.lang.Object
      org.apache.tomcat.util.http.parser.MediaTypeCache

    public class MediaTypeCache

extends java.lang.Object

Caches the results of parsing content-type headers.

Constructor Summary
`MediaTypeCache(int size)`

Method Summary
`java.lang.String[]` | `parse(java.lang.String input)` Looks in the cache and returns the cached value if one is present.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### MediaTypeCache

    public MediaTypeCache(int size)

Method Detail

### parse

    public java.lang.String[] parse(java.lang.String input)

  Looks in the cache and returns the cached value if one is present. If no match exists in the cache, a new parser is created, the input parsed and the results placed in the cache and returned to the user.

  Parameters:
    `input` - The content-type header value to parse
  Returns:
    The results are provided as a two element String array. The first element is the media type less the charset and the second element is the charset

Overview | Package | Class | Tree | Deprecated | Index | Help
| Apache Tomcat 6.0.51
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2000-2017 Apache Software Foundation. All Rights Reserved.