Search in sources :

Example 1 with DefaultRuntimeCamelCatalog

use of org.apache.camel.catalog.DefaultRuntimeCamelCatalog in project camel by apache.

the class EndpointHelper method endpointProperties.

/**
     * Parses the endpoint uri and builds a map of documentation information for each option which is extracted
     * from the component json documentation
     *
     * @param camelContext the Camel context
     * @param uri          the endpoint uri
     * @return a map for each option in the uri with the corresponding information from the json
     * @throws Exception is thrown in case of error
     * @deprecated use {@link org.apache.camel.catalog.RuntimeCamelCatalog#endpointProperties(String)}
     */
@Deprecated
public static Map<String, Object> endpointProperties(CamelContext camelContext, String uri) throws Exception {
    RuntimeCamelCatalog catalog = new DefaultRuntimeCamelCatalog(camelContext, false);
    Map<String, String> options = catalog.endpointProperties(uri);
    return new HashMap<>(options);
}
Also used : HashMap(java.util.HashMap) LinkedHashMap(java.util.LinkedHashMap) DefaultRuntimeCamelCatalog(org.apache.camel.catalog.DefaultRuntimeCamelCatalog) RuntimeCamelCatalog(org.apache.camel.catalog.RuntimeCamelCatalog) DefaultRuntimeCamelCatalog(org.apache.camel.catalog.DefaultRuntimeCamelCatalog)

Aggregations

HashMap (java.util.HashMap)1 LinkedHashMap (java.util.LinkedHashMap)1 DefaultRuntimeCamelCatalog (org.apache.camel.catalog.DefaultRuntimeCamelCatalog)1 RuntimeCamelCatalog (org.apache.camel.catalog.RuntimeCamelCatalog)1