Interface SourceLoader

All Known Implementing Classes:
DefaultSourceLoader

public interface SourceLoader
Loader for loading the source code from Resource. Custom SourceLoader implementations can be plugged into the CamelContext by adding to the Registry.
  • Method Summary

    Modifier and Type
    Method
    Description
    loadResource(org.apache.camel.spi.Resource resource)
    Loads the source from the given resource
  • Method Details

    • loadResource

      String loadResource(org.apache.camel.spi.Resource resource) throws IOException
      Loads the source from the given resource
      Parameters:
      resource - the resource
      Returns:
      the source code (such as java, xml, groovy, yaml)
      Throws:
      IOException - is thrown if error loading the source