@ProtoFactory
   public static MediaType fromString(String tree) {
      if (tree == null || tree.isEmpty()) throw CONTAINER.missingMediaType();

      Matcher matcher = TREE_PATTERN.matcher(tree);
      return parseSingleMediaType(tree, matcher, false);
   }
@Test(expected = EncodingException.class)
   public void testParsingNull() {
      MediaType.fromString(null);
   }