Class MediaTypeMatcher<T>


  • public class MediaTypeMatcher<T>
    extends java.lang.Object
    Helper class that picks an object from a MediaType map from a list of sorted acceptable MediaTypes
    Version:
    $Revision: 1 $
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected java.util.Map<javax.ws.rs.core.MediaType,​T> representations  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.Map<javax.ws.rs.core.MediaType,​T> getRepresentations()  
      T match​(java.util.List<javax.ws.rs.core.MediaType> accepts)  
      void setRepresentations​(java.util.Map<javax.ws.rs.core.MediaType,​T> representations)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • representations

        protected java.util.Map<javax.ws.rs.core.MediaType,​T> representations
    • Constructor Detail

      • MediaTypeMatcher

        public MediaTypeMatcher()
    • Method Detail

      • getRepresentations

        public java.util.Map<javax.ws.rs.core.MediaType,​T> getRepresentations()
      • setRepresentations

        public void setRepresentations​(java.util.Map<javax.ws.rs.core.MediaType,​T> representations)
      • match

        public T match​(java.util.List<javax.ws.rs.core.MediaType> accepts)