code: public <T> void setFormatter( Class<T> typeToBeFormatted, Formatter<T> formatter ) {
          formatterCache.setFormatter( typeToBeFormatted, formatter );
      }
docs: Sets the formatter for the given type.
  <p>
  When choosing a formatter, JGiven will take the formatter defined for the most specific
  super type of a given type.
  <p>
  If no formatter can be found for a type, the {@link com.tngtech.jgiven.format.DefaultFormatter} is taken.
  <p>
  For example,
  given the following formatter are defined:
  
  <pre>
  setFormatter( Object.class, formatterA );
  setFormatter( String.class, formatterB );
  </pre>
  
  When formatting a String,<br>
  Then {@code formatterB} will be taken.
  <p>
  If formatter for multiple super types of a type are defined, but these types have no subtype relation, then an arbitrary
  formatter is taken in a non-deterministic way. Thus you should avoid this situation.
  <p>
  For example,
  given the following formatter are defined:
  
  <pre>
  setFormatter( Cloneable.class, formatterA );
  setFormatter( Serializable.class, formatterB );
  </pre>
  
  When formatting a String,<br>
  Then either {@code formatterA} or {@code formatterB} will be taken non-deterministically.
  <p>
  The order in which the formatter are defined, does not make a difference.
  <p>
  Note that the formatter can still be overridden by using a formatting annotation.
  
  @param typeToBeFormatted the type for which the formatter should be defined
  @param formatter the formatter to format instances of that type