code: @SuppressWarnings("unchecked")
      public <T> Serializer<T> getSerializer(Class<T> type, String mediaType) throws SerializationException {
          checkNotNull(type, "Type (Class<T>) cannot be null.");
          checkNotNull(mediaType, "Media-Type cannot be null.");
  
          final String typeName = getClassName(type);
          final Key key = new Key(typeName, mediaType);
  
          logger.log(Level.FINE, "Querying for Serializer of type '" + typeName + "' and " + "media-type '" + mediaType
                  + "'.");
  
          ArrayList<SerializerHolder> holders = serializers.get(typeName);
          if (holders != null) {
              for (SerializerHolder holder : holders) {
                  if (holder.key.matches(key)) {
                      logger.log(Level.FINE, "Serializer for type '" + holder.serializer.handledType() + "' and " +
                              "media-type '" + Arrays.toString(holder.serializer.mediaType()) + "' matched: " +
                              holder.serializer.getClass().getName());
                      return (Serializer<T>) holder.serializer;
                  }
              }
          }
  
          logger.log(Level.WARNING, "There is no Serializer registered for type " + type.getName() +
                  " and media-type " + mediaType + ". If you're relying on auto-generated serializers," +
                  " please make sure you imported the correct GWT Module.");
  
          return null;
      }
docs: Retrieve Serializer from manager.
  
  @param type The type class of the serializer.
  @param <T> The type of the serializer.
  @return The serializer of the specified type.
  
  @throws SerializationException if no serializer was registered for the class.