anchor.diff:  [[TypeConverter-Addtypeconverterclassesatruntime]]
   === Add type converter classes at runtime
   
  -You can add new type converters at runtime, by having your classes
  -implement `org.apache.camel.TypeConverters` which is an marker
  -interface. Then for each type converter you want use
  -the `@Converter` annotation.
  +Classes implementing https://www.javadoc.io/doc/org.apache.camel/camel-api/latest/org/apache/camel/TypeConverters.html[`TypeConverters`] are added to the type converter registry
  +at runtime. Use https://javadoc.io/doc/org.apache.camel/camel-api/latest/org/apache/camel/Converter.html[`@Converter`] to mark each type converter.
   
   [source,java]
   ----
  
positive.code: [[TypeConverter-TypeConverter]]
  = Type Converter
  
  It is very common when routing messages from one endpoint to another to
  need to convert the body payloads from one type to another such as to
  convert to and from the following common types:
  
  * File
  * String
  * byte[] and ByteBuffer
  * InputStream and OutputStream
  * Reader and Writer
  * Document and Source
  * ...
  
  The
  https://www.javadoc.io/doc/org.apache.camel/camel-api/current/org/apache/camel/Message.html[Message
  interface] defines a helper method to allow conversions to be done via
  the
  https://www.javadoc.io/doc/org.apache.camel/camel-api/current/org/apache/camel/Message.html#getBody-java.lang.Class-[getBody(Class)]
  method.
  
  So in an endpoint you can convert a body to another type via:
  
  [source,java]
  ----
  Message message = exchange.getIn();
  Document document = message.getBody(Document.class);
  ----
  
  [[TypeConverter-HowTypeConversionworks]]
  == How Type Conversion works
  
negative.code: </camelContext>
  ----
  
  In Spring Boot `application.properties`:
  
  [source,properties]
  ----
  camel.springboot.load-type-converters=true
  ----
  
  Camel will discover Camel 2.x compatible type converters by
  searching the classpath for a file called `META-INF/services/org/apache/camel/TypeConverter`
  which lists all type converter classes. These classes are automatically registered in the type converter
  registry. However, invoking these type converters does **not** happen in a _fast way_ and uses the Java Reflection API.
  It is therefore recommended to upgrade any type converters to use the faster way. See below for more details.
  
  TIP: You can turn off the fallback of discovering Camel 2.x compatible type converters by
  setting `CamelContext.setLoadTypeConverters(false)`.
  
  `@Converter` must appear at the class and method level for each type converter.
  
  .Register a type converter from `File` to `InputStream`
  
  [source,java]
  ----
  